123ArticleOnline Logo
Welcome to 123ArticleOnline.com!
ALL >> Education >> View Article

Detecting Parkinson’s Disease

Profile Picture
By Author: data science
Total Articles: 14
Comment this article
Facebook ShareTwitter ShareGoogle+ ShareTwitter Share

Parkinson's disease is a condition that affects the central nervous system. It is a sickness in which the neurological system is disrupted. Its symptoms are caused by a lack of dopamine in the brain. Four Tremor, rigidity, delayed movement, and balance issues are the most common symptoms. Parkinson's disease is a movement disorder that affects the human body. Around 1 million persons worldwide are affected by this condition today. Because there is currently no cure for Parkinson's Disease, treatment focuses on reducing the symptoms. This is a condition that causes dopamine-producing neurons in the brain to degenerate.

About the Parkinson's Disease Detection Project

Parkinson's disease is a neurological condition that affects the brain. It causes tremors in the body and hands, as well as stiffness in the body. Because our output comprises only 1s and 0s, we will use one of the Classifier approaches known as RandomForestClassifier in this Python machine learning project to develop a model to detect Parkinson's illness. At this moment, there is no proper cure or treatment available. We'll import the dataset, extract ...
... the features and targets, divide them into training and testing sets, and then send them to RandomForestClassifier for classification. Only when the disease is caught early enough can it be treated. So, it is one of the best data science project ideas for beginners and experts as well.

Parkinson's disease (PD) is a neurodegenerative illness that affects the nervous system and belongs to the category of disorders known as motor system disorders. The majority of available methods can detect Parkinson's disease in its advanced stages, which indicates a loss of approximately 60% dopamine in the basal ganglia, which is responsible for coordinating bodily movement with a tiny amount of dopamine. Parkinson's disease patients' basic physical processes, such as breathing, balance, movement, and heart function, deteriorate over time.
Alzheimer's disease, Huntington's disease, and amyotrophic lateral sclerosis, also known as Lou Gehrig's disease, are examples of neurodegenerative diseases. In the United Kingdom, over 145,000 people have been identified alone suffering, while in India, nearly one million people are affected by the sickness, which is rapidly spreading throughout the world. Parkinson's disease affects an estimated seven to ten million people worldwide. Enroll at Learnbay: best data science course in Bangalore for more details.

Data mining techniques in medicine is a field of study that blends advanced representational and computing approaches with professional physician perspectives to create tools for bettering healthcare. Gene mutations frequently enhance the risk of Parkinson's disease, but each genetic marker has a smaller influence. Data mining is a computational process for uncovering hidden patterns in information by constructing prediction or classification models that may be learned from previous cases and applied to new ones. The condition can be triggered by dangerous poisons or chemical chemicals found in the environment, but they have a minor effect.
With a large amount of medical data available to hospitals, medical centers, and medical research organizations, the field of medicine can improve healthcare quality and assist clinicians in making decisions about their patients' treatment using data mining techniques. To see which algorithm is the best for detecting the onset of disease, we'll employ XGBoost, KNN, SVMs, and the Random Forest Algorithm.
Support vector machines (SVM), neural networks, decision trees, and Nave Bayes are examples of classification techniques. The study's goal is to examine and compare the performance of four of the above-mentioned classification algorithms after a Parkinson's diagnosis. We assess the performance of the classifiers on actual and discretized PD datasets first and then compare their performance using the attributes selection approach.

Prerequisites
I installed the following libraries through pip:

Code:
pip install numpy pandas sklearn xgboost

Importing the Required Libraries
Importing all of the relevant modules into our project is the initial step in every project. We'll start by importing all of the essential libraries, which were discussed in the prerequisites section. To prepare, load, and plot data, we'll need some fundamental modules such as numpy, pandas, and matplotlib.

Code:
import numpy as np
import pandas as pd
import os, sys
from sklearn.preprocessing import MinMaxScaler
from xgboost import XGBClassifier
from sklearn.model_selection import train_test_split
from sklearn.metrics import accuracy_score

Loading the Dataset
Obtain the data frame's features and targets. The last step is to place the data that we previously downloaded in the same folder as the code file. The panda's module is used for this, and the code for it may be found below.

Code:

dataframe=pd.read_csv('parkinsons.csv')
print("The shape of data is: ",dataframe.shape,"\n")
print("FIRST FIVE ROWS OF DATA ARE AS FOLLOWS: \n")
dataframe.head()

Normalization
Our feature data will be scaled between -1 (lowest value) and 1 (highest value) (maximum value). MinMaxScaler would be used to convert features and scale them to a specified range as a parameter. Scaling is critical because variables at different sizes may not contribute equally to model fitting, which can lead to bias. The fit transform function aids in the fitting of data before it is transformed or normalized.

Code:

#scale all the features data in the range between -1,1
scaler= MinMaxScaler((-1,1))
features_c=scaler.fit_transform(features)


Train-Test Split of data
The next stage is to divide the data into training and testing groups using the 80-20 rule, which allocates 80% of the data to training and 20% to testing. Split the dataset into an 80:20 ratio, with 80 rows used for training and 20 rows used for testing.
To accomplish this, we'll use the sklearn module's train test split method. The code can be found below. For this, we will pass scaled features and target data to ‘train_test_split()’.

Code:
x_train,x_test,y_train,y_test=train_test_split(x_data,y_data,test_size=0.2)

Building the classifier model
For the classification of our data points, we'll utilise a Random Forest Classifier. Our data have now been trained and is ready to be entered into the XBGClassifier. So, let's have a look at what a random forest is. To get the same result, we'll design a classifier object and then fit the training data into it.

Code:
model=XGBClassifier()
model.fit(x_train,y_train)

Prediction and Accuracy
Now, we'll use the model we've trained to forecast our output(y pred) for testing data(x test), which makes up 20% of the dataset. The following and final stage is to obtain predictions for the testing dataset and measure our model's accuracy. We'll also calculate our model's accuracy, mean absolute error, and root means square error.

Code:
#predict the output for x_test
y_pred=model.predict(x_test)
#calculate accuracy,root mean squared error
print('Accuracy :',accuracy_score(y_test, y_pred))
print('Mean Absolute Error:', mean_absolute_error(y_test, y_pred))
print('Root Mean Squared Error:', np.sqrt(mean_squared_error(y_test, y_pred)))

So there you have it! We created our own Parkinson's disease classification system.

Final Thoughts

Hence Detecting Parkinson’s disease is one of the top data science project ideas for beginners and experts. The goal of this study was to see how different classifiers would perform when applied to the PD dataset, to evaluate their performance, and to see how to attribute selection, discretization, and test mode affected the performance of the selected classifier when applied to the PD dataset. If you're interested in learning more about data science courses or data science projects, visit our Learnbay website. We offer the most comprehensive data science course in Bangalore, along with clear explanations. We provide the best data science course in Bangalore with detailed explanations.

In this data science project, we created a model to predict whether or not a person has Parkinson's Disease using the RandomForestClassifier of the sklearn module of Python. Because our dataset comprises fewer records, we were able to achieve 97.33 percent accuracy with the machine learning model.

Check details related to best data science course in Bangalore at Learnbay.co, https://www.learnbay.co/data-science-course/data-science-course-in-bangalore/.

Total Views: 181Word Count: 1202See All articles From Author

Add Comment

Education Articles

1. Which Books Have Been Published By Iiag Jyotish Sansthan Founder Dr. Yagyadutt Sharma?
Author: Yagya Dutt Sharma

2. Sap Sd Training In Bangalore
Author: VITSAP

3. Agile Scrum Methodology Explained In Simple Terms For Beginners
Author: Learnovative

4. Blue Wizard Liquid Drops 30 Ml 2 Bottles Price In Hyderabad
Author: bluewizard.pk

5. How Java Skills Can Open Doors To Global It Careers – Sssit Computer Education
Author: lakshmisssit

6. How Digital Marketing Can Help You Switch Careers
Author: madhuri

7. Ryan Group Of Institutions Partners With Royal Grammar School Guildford, A 500-year-old Institution - To Launch Premium British Curriculum Schools In
Author: Lochan Kaushik

8. Join Site Reliability Engineering Training Hyderabad | Visualpath
Author: krishna

9. Top 7 Tips From An Mbbs Admission Consultant In India
Author: Rima

10. An Ultimate Guide To Mbbs In Russia; An Ideal Destination To Study Mbbs Course!
Author: Mbbs Blog

11. A Complete Overview Of Mbbs In Nepal!
Author: Mbbs Blog

12. Affordable Online Mba’s With Global Recognition...
Author: University Guru

13. Induction Training: Building Strong Foundations For New Employees
Author: edForce

14. Dynamics 365 Training In Hyderabad | Online D365 Course
Author: Hari

15. Why Aima Leads In Post Graduate Diploma In Management Excellence
Author: Aima Courses

Login To Account
Login Email:
Password:
Forgot Password?
New User?
Sign Up Newsletter
Email Address: