Among the many applications of machine learning, one is of particular interest to me. The use of disease detection in machine learning has the potential to help a large number of people in the world and the advent of machine learning and computer vision in the past few years have definitely transformed the fields of medicine, finance, biotechnology and more. The use of disease detection methods using machine learning and computer vision has a number of applications in the medical sector and its use is only expected to grow exponentially as we develop better methods and models. he value of machine learning in healthcare is its ability to process huge datasets beyond the scope of human capability, and then reliably convert analysis of that data into clinical insights that aid physicians in planning and providing care, ultimately leading to better outcomes, lower costs of care, and increased patient satisfaction.
Many leading tech companies and universities have been doing research on the use of AI in the medical sector. For example, Google has developed a machine learning algorithm to help identify cancerous tumors on mammograms. Stanford is using a deep learning algorithm to identify skin cancer. Such revolutionary and pioneering research motivates enthusiasts of machine learning and computer vision like me to study more and more about these practices and the methods used to develop them.
I am here with an example of a disease detection app which detects if you have breast cancer based upon a number of features such as radius, age, texture, perimeter, area, smoothness, compactness, concavity, concave points, symmetry and fractal dimension. I will explain more about these parameters shortly. This web app is based on machine learning and uses the Random Forest Classifier Classification Algorithm. The app is coded majorly in python.
We have deployed the app using Streamlit. It is an open source framework that allows data science teams to deploy web apps fairly easily. It’s one of the best hosting services I’ve used and it’s great for quick and easy deployment of web apps. The app is coded in python. The web app uses interactive visual and graphical interpretations to display the outcome and compare the input parameters given by the user. The graphs compare the values of the patient with others ( both with cancerous and non-cancerous patients). It also provides the accuracy of the result which ranges from around 90-95%.
A value of 0 on the graphs represents a benign i.e. non-cancerous tumor and a value of 1 represents a malignant i.e. a cancerous tumor. This web app was a learning curve for us and has improved our knowledge about Machine learning significantly. We hope to deploy more apps in the future and share them with you. Feel free to add onto this project and don’t hesitate to drop by any suggestions. The link for the Breast Cancer Detection web app is as follows : https://share.streamlit.io/braxtonova/cancer/main/app.py
About the dataset: The dataset used is the Wisconsin Breast Cancer dataset created by researchers at the University of Wisconsin. It consists of the following parameters: radius (mean of distances from center to points on the perimeter), texture (standard deviation of gray-scale values), perimeter, area, smoothness (local variation in radius lengths), compactness (perimeter^2 / area – 1.0), concavity (severity of concave portions of the contour), concave points (number of concave portions of the contour), symmetry and fractal dimension (“coastline approximation” – 1). For those of you who are not familiar with the terms in statistics, my article about Exploratory Data Analysis can be a good starting point.
I will provide a brief idea about contours and the coastline paradox (one of my favorite mathematical paradoxes) in this article. In layman terms, an outline representing or bounding the shape or form of something is called a contour. However, we state this is calculus and linear algebra as: a line joining points on a diagram at which some property has the same value. A contour line (also isoline, isopleth, or isarithm) of a function of two variables is a curve along which the function has a constant value, so that the curve joins points of equal value. It is a plane section of the three-dimensional graph of the function f(x, y) parallel to the (x, y)-plane.Contour lines are curved, straight or a mixture of both lines on a map describing the intersection of a real or hypothetical surface with one or more horizontal planes. I’d also like to mention about contour integrals, which is a method of evaluating certain integrals along paths in the complex plains. Contour integration is also closely related to complex analysis, application of the residue theorem, Cauchy Integral formula etc.
I could talk about these all day but lets move onto the coastline paradox. The coastline paradox revolves around the seemingly simple notion that the coastline of a landmass does not have a well defined length. This results from the fractal curve-like properties of coastlines, i.e., the fact that a coastline typically has a fractal dimension (which in fact makes the notion of length inapplicable). The first recorded observation of this phenomenon was by Lewis Fry Richardson and it was expanded upon by Benoit Mandelbrot. The measured length of the coastline depends on the method used to measure it and the degree of cartographic generalization.
Disclaimer: This is just a learning project based on one particular dataset so please do not depend on it to actually know if you have breast cancer or not. It might still be a false positive or false negative. A doctor is still the best fit for the determination of such diseases.
Breast Cancer Awareness Month, also referred to in the United States as National Breast Cancer Awareness Month, is an annual international health campaign organized by major breast cancer charities every October to increase awareness of the disease and to raise funds for research into its cause, prevention, diagnosis, treatment and cure. The National Breast Cancer Awareness month was founded in 1985 as a partnership between the American Cancer Society and the pharmaceutical divisions of Imperial Chemical Industry (now a part of Astrazeneca). The aim of this was to promote mammography as the most effective weapon in the fight against breast cancer. Let’s support this initiative and promote the awareness of this disease among the masses.
Note: Some of you’ll mentioned that the prediction is always a malignant tumor, that might be the case as the dataset contains relatively a less number of benign data points. Although, if you vary the values of texture and radius you should see the prediction come out as benign for certain cases.
Explanation of the Code and how you can make this yourself !
Here, I am going to go through the code in a very concise and simple manner so that people with even minimal experience in programming or data science can follow along and benefit it. This app has been coded in python and has been deployed on streamlit as mentioned before. I’ve also used the Random Forest Classifier Algorithm for this particular problem.
Alright so lets finally get started. First up I’ve imported the python packages / libraries that I’ve used for this app. More information for them is available on the project template of SkillTools.
import streamlit as st
import pandas as pd
from PIL import Image
import numpy as np
import matplotlib.pyplot as plt
import plotly.figure_factory as ff
from sklearn.metrics import accuracy_score
from sklearn.ensemble import RandomForestClassifier
from sklearn.model_selection import train_test_split
import seaborn as sns
from PIL import Image
After this I have included a slight description of the app as a string which includes the dataset resource and the developers. After which we need to feed in our dataset and define some headings to that the users can know what this is.
df = pd.read_csv(r'data.csv')
#titles
st.sidebar.header('Patient Data')
st.subheader('Training Dataset')
st.write(df.describe())
After this we need to train and test our data. For the purpose of this app, I’ve used the test size and train size as 20% and 80% respectively.
x = df.drop(['Outcome'], axis = 1)
y = df.iloc[:, -1]
x_train, x_test, y_train, y_test = train_test_split(x,y, test_size = 0.2, random_state = 0)
Once we’re done with this, we need to define the user report and the user report data depending on the various parameters given in the training dataset. For this particular dataset the parameters are Age, Radius, Texture, Perimeter, Area, Smoothness, Compactness, Concavity, Concave Points, Symmetry and number of fractal dimensions. We also need to mention the range of values of these parameters so that the user can change them using the sliders in the sidebar.
def user_report():
Age = st.sidebar.slider('Age', 0,100, 54)
Radius = st.sidebar.slider('Radius', 0,30, 15 )
Texture = st.sidebar.slider('Texture', 0,40, 20 )
Perimeter = st.sidebar.slider('Perimeter', 40,200, 92 )
Area = st.sidebar.slider('Area', 140,2600, 650 )
Smoothness = st.sidebar.slider('Smoothness', 0.0,0.25, 0.1 )
Compactness = st.sidebar.slider('Compactness', 0.0,0.4, 0.1 )
Concavity = st.sidebar.slider('Concavity', 0.0,0.5, 0.1 )
Concave_points = st.sidebar.slider('Concave points', 0.0,0.25, 0.05 )
Symmetry = st.sidebar.slider('Symmetry', 0.0,0.4, 0.2 )
Fractal_Dimension = st.sidebar.slider('Fractal Dimension', 0.0,0.1, 0.06 )
user_report_data = {
'Age':Age,
'Radius':Radius,
'Texture':Texture,
'Perimeter':Perimeter,
'Area':Area,
'Smoothness':Smoothness,
'Compactness':Compactness,
'Concavity':Concavity,
'Concave_points':Concave_points,
'Symmetry':Symmetry,
'Fractal_Dimension':Fractal_Dimension,
}
report_data = pd.DataFrame(user_report_data, index=[0])
return report_data
user_data = user_report()
st.subheader('Patient Data')
st.write(user_data)
Now here’s the part that we run the Random Forest Classifier Algorithm, fit the data and run the model based on the input dataset.
rf = RandomForestClassifier()
rf.fit(x_train, y_train)
user_result = rf.predict(user_data)
Now we finally come to my most favourite part of these web apps: Visualizations. I have been experimenting a lot with a number of visualization libraries but some of them really stand out for me and I use them often in my apps. So here as a convention I’ve used blue colour for healthy patients and the colour red for unhealthy patients.
st.title('Graphical Patient Report')
if user_result[0]==0:
color = 'blue'
else:
color = 'red'
We start off with Radius and code in its visualizations. Here I’ve basically plotted a seaborn scatterplot with age on the x axis and the values of the Radius parameter on the y axis. I have used the purple palette and have scaled the axes according to the data. A value of 0 represents a healthy case whereas a value of 1 represents an unhealthy case.
st.header('Radius Value Graph (Yours vs Others)')
fig_Radius = plt.figure()
ax3 = sns.scatterplot(x = 'Age', y = 'Radius', data = df, hue = 'Outcome' , palette='Purples')
ax4 = sns.scatterplot(x = user_data['Age'], y = user_data['Radius'], s = 150, color = color)
plt.xticks(np.arange(0,100,5))
plt.yticks(np.arange(0,50,5))
plt.title('0 - Healthy & 1 - Unhealthy')
st.pyplot(fig_Radius)
Now that we are done with one parameter, we can very easily do this same for the other parameters as well. Just replace the above code snippet with that of the other parameters and you are set to go. I will leave this as an exercise for you’ll and if you have any queries regarding it, please do ask. After completing the visualizations for all the parameters, we are finally ready to display the outcome and the prediction. I have given the outcome in the form of a user report.
st.subheader('Your Report: ')
output=''
if user_result[0]==0:
output = 'Congratulations, you do not have Breast Cancer'
else:
output = 'Unfortunately, you do have Breast Cancer'
st.title(output)
st.subheader('Accuracy: ')
st.write(str(accuracy_score(y_test, rf.predict(x_test))*100)+'%')
Next, I have duly given the dataset credits to the respective owners and authorities in charge of this dataset and have adhered to its license which is Attribution-NonCommercial-ShareAlike 4.0 International (CC BY-NC-SA 4.0) in this case. I have also mentioned where I received the dataset from (UCI Machine Learning Repository) and have cited the original creators of this dataset for their commendable work.
To cap up this web app, I’ve given a disclaimer that I give for all my BioTechnology and medical applications of data science that this is an application based on one particular dataset so we cannot use it universally. I have also attached the logo of Skillocity at the end.
So that’s it from this web app and I’ll see you soon with another fun application of Machine Learning / Data Science and give some interesting insights. Hasta pronto !
Kız yarragı nekadar güzel yalıyor yahu kızla sikişmek de ayrı bir güzellik daha amına sik geçmemiş bakire
masum liseli türk kızla sikiş izle.
👉 Jill He wants to talk frankly with you and show you something, you will like it. Click Here:👉 http://bit.do/fVzCM
A secret weapon for anyone who needs content. I dont need to tell you how important it is to optimize every step in your SEO pipeline. But unfortunately, its nearly impossible to cut out time or money when it comes to getting good content. At least thats what I thought until I came across Article Forge. Built by a team of AI researchers from Stanford, MIT, Carnegie Mellon, Harvard, Article Forge is an AI content writer that uses deep learning models to research, plan out, and write entire articles about any topic with the click of a button. Their team trained AI models on millions of articles to teach Article Forge how to draw connections between topics so that each article it writes is relevant, interesting and useful. All their hard work means you just enter a few keywords and Article Forge will write a complete article from scratch making sure every thought flows naturally into the next, resulting in readable, high quality, and unique content. Put simply, this is a secret weapon for anyone who needs content. I get how impossible that sounds so you need to see how Article Forge writes a complete article with the Click Here:👉 https://stanford.io/3FXszd0
Free. Sign up to receive $100, Trade to receive $5500. Click Here:👉 https://millionairego.page.link/free
levaquin pill levofloxacin buy online
buy avodart pill zofran usa brand zofran 8mg
aldactone 25mg without prescription aldactone 25mg without prescription order diflucan 200mg sale
ampicillin for sale online purchase bactrim sale erythromycin for sale online
sildenafil for sale buy sildenafil 100mg online methocarbamol without prescription
sildenafil 100mg cheap sildenafil 20mg order estrace 2mg for sale
purchase lamotrigine generic lamotrigine for sale tretinoin canada
order tadalafil pill purchase tadalis generic voltaren over the counter
order accutane 40mg pill order accutane 10mg cost zithromax
indocin 50mg cost buy suprax 100mg pill order trimox 500mg pills
tadalafil 5mg over the counter canadian drugs online sildenafil order
arimidex for sale oral arimidex 1mg sildenafil usa
generique tadalafil 20mg vrai cialis 40mg prix sildenafil 25mg sans ordonnance
buy deltasone 40mg generic best place to buy generic cialis purchasing viagra on the internet
tadalafil fГјr frauen original sildenafil 100mg rezeptfrei sicher kaufen sildenafil generika rezeptfrei kaufen
order isotretinoin sale amoxil for sale ivermectina 6mg
modafinil usa Free trial of cialis diamox cheap
doxycycline 100mg pills buy lasix pills buy lasix online cheap
buy ramipril 10mg pill order avapro pills order astelin 10 ml online
catapres 0.1mg pill order antivert 25mg buy spiriva without prescription
cost buspar 10mg order buspirone 10mg without prescription cheap ditropan 5mg
hytrin 5mg pills terazosin 5mg brand azulfidine price
fosamax buy online buy famotidine 40mg order famotidine 20mg pills
benicar cheap buy calan generic acetazolamide canada
buy tacrolimus 1mg generic order ropinirole 2mg online buy ursodiol 300mg pills
imdur 20mg cost digoxin generic micardis medication
buy generic bupropion buy cetirizine online cheap buy seroquel generic
buy molnupiravir 200 mg without prescription purchase molnunat online cheap order lansoprazole 30mg online
buy zoloft sale kamagra order viagra 50mg for sale
salbutamol generic sildenafil professional sildenafil brand
бесплатно порно чат. Click Here:👉 http://rt.livepornosexchat.com/
tadalafil 10mg ca order cialis online cheap viagra generic
buy tadalafil online cheap cialis 10mg canada amantadine 100mg cost
промокод для melbet. Click Here:👉 http://lynks.ru/geshi/php/?melbet_promokod_pri_registracii_2020.html
buy generic revia buy letrozole online buy aripiprazole sale
avlosulfon 100 mg canada buy allegra generic buy aceon 4mg
buy provera 5mg pills microzide 25 mg brand buy cyproheptadine 4mg generic
order modafinil 100mg pills stromectol medication ivermectin uk buy
order luvox online buy ketoconazole for sale glucotrol 5mg drug
accutane 20mg oral deltasone for sale online prednisone pill
nootropil 800 mg us generic piracetam 800 mg generic sildenafil 50mg
zithromax cost order neurontin 600mg pill order neurontin 800mg online
cialis 5mg for sale buy sildenafil pills viagra sildenafil 200mg
lasix 100mg usa buy doxycycline 200mg generic buy generic hydroxychloroquine 400mg
cialis pharmacy cialis 40mg usa anafranil 50mg without prescription
chloroquine order cenforce drug olumiant 2mg drug
buy sporanox 100 mg generic prometrium 200mg pill cost tinidazole 300mg
glucophage 1000mg us oral atorvastatin cheap tadalafil pill
zyprexa 10mg uk order diovan 80mg for sale valsartan medication
buy norvasc 10mg for sale viagra australia cialis 5mg ca
clozapine medication order combivent 100 mcg online cheap dexamethasone for sale online
us viagra buy viagra 50mg pill order lisinopril 5mg pills
zyvox 600 mg uk blackjack card game free online blackjack
omeprazole 20mg oral order research paper online poker
lopressor for sale online metoprolol online vardenafil 10mg tablet
write papers online empire casino online can you play poker online money
buy vardenafil generic pregabalin 75mg without prescription purchase medrol
academicwriting best essay writers online sildenafil 50mg pills for men
order clomid for sale real money casino games spins real money online
tadalafil usa real cialis pharmacy prescription viagra online order
buy triamcinolone online cheap buy aristocort 10mg generic purchase clarinex online cheap
dapoxetine 30mg cost buy priligy sale purchase synthroid generic
tadalafil 5mg us order sildenafil viagra 100mg
xenical cheap order orlistat acyclovir 800mg drug
order cialis 40mg online cheap inderal oral clopidogrel 150mg tablet
order generic allopurinol 300mg zetia order cheap ezetimibe 10mg
cost methotrexate 5mg purchase reglan pills order reglan 20mg pills
generic domperidone 10mg sumycin over the counter order flexeril online
cozaar price purchase topamax pills brand topiramate 100mg
coursework jamii forum coursework guidelines jcq coursework malpractice coursework plural
lioresal medication tizanidine ca purchase toradol pill
buy sumatriptan pill cheap levaquin 500mg cheap avodart
order colchicine generic play casino online online blackjack for real money usa
zantac 150mg over the counter order ranitidine 150mg without prescription celecoxib 100mg oral
roulette online real money online roulette game casino card games
order flomax 0.2mg online cheap order flomax 0.4mg online buy aldactone 25mg pills
cialis generic name cipro 500mg ca ciprofloxacin over the counter
zocor 20mg cost order generic zocor proscar 1mg without prescription
buy metronidazole 400mg online cheap order bactrim 960mg pill buy bactrim online cheap
coursework structure coursework and research difference coursework writing uk coursework in english
coursework guidelines 9396 coursework rule usyd coursework
on resume example coursework master
purchase fluconazole online cheap fluconazole 100mg pills viagra in usa
coursework writing service uk coursework common app degree coursework quantitative coursework examples
coursework requirements coursework jelentése coursework
based masters coursework at a college or university
buy cephalexin 250mg online cheap cleocin online buy order erythromycin without prescription
course work l�ꫣoursework login coursework writer uk coursework translate coursework cover page
java coursework coursework job meaning degree coursework coursework
coursework examination creative writing coursework
coursework other than a-g qmul coursework extension
coursework for psychology degree coursework for nursing coursework guidelines coursework mark
buy cialis online sildenafil 100mg us viagra cost
brand name viagra buy sildenafil 50mg online cheap tadalafil 40mg sale
cefuroxime 500mg over the counter purchase careprost methocarbamol 500mg for sale
best casino real online casino cheap tadalafil 40mg
https://over-the-counter-drug.com/# what does over the counter mean
buy generic trazodone order desyrel 50mg generic buy sildenafil 50mg generic
help writing research paper order stromectol online cheap ivermectin 6mg for sale
sildenafil 50mg for sale order generic lamotrigine 50mg cost lamictal 50mg
https://doxycycline.science/# doxycycline 100mg dogs
order deltasone 40mg pills order amoxil 500mg generic buy amoxicillin 250mg
female viagra sildenafil buy tadalafil 5mg cialis 5mg tablet
https://stromectol.science/# ivermectin eye drops
rivers casino online ed medications cialis 40mg tablet
zithromax 500mg for sale cheap neurontin 800mg buy gabapentin 600mg online
https://stromectol.science/# ivermectin 3mg tablet
blackjack vegas free online games modafinil price buy modafinil
purchase furosemide generic order plaquenil for sale hydroxychloroquine pills
Generic Name. Commonly Used Drugs Charts.
https://stromectolst.com/# stromectol 3 mg
Everything information about medication. Drugs information sheet.
Actual trends of drug. Prescription Drug Information, Interactions & Side.
https://stromectolst.com/# ivermectin australia
What side effects can this medication cause? safe and effective drugs are available.
Medicament prescribing information. Get warning information here.
https://stromectolst.com/# ivermectin 2ml
Best and news about drug. Learn about the side effects, dosages, and interactions.
All trends of medicament. Read here.
where to buy stromectol online
Actual trends of drug. Generic Name.
All trends of medicament. safe and effective drugs are available.
https://stromectolst.com/# ivermectin iv
Get warning information here. Everything about medicine.