IoT Based Illness Prediction System Using Machine Learning
IoT Based Illness Prediction System Using Machine Learning
Learning
A Seminar Report
Submitted to the APJ Abdul Kalam Technological University
in partial fulfillment of requirements for the award of degree
Bachelor of Technology
in
Computer Science and Engineering
by
Faiz
EKC21CS017
CERTIFICATE
This is to certify that this Seminar Report titled IoT based Illness Prediction
System using Machine Learning is the bonafide record of the work done by Faiz
(EKC21CS017) of seventh semester, Computer Science and Engineering, Eranad
Knowledge City Technical Campus, towards the partial fulfillment of the requirements
for the award of the Degree of Bachelor of Technology by the A P J Abdul Kalam
University.
I Faiz hereby declare that the seminar report IoT based Illness Prediction System
using Machine Learning , submitted for partial fulfillment of the requirements for the
award of degree of Bachelor of Technology of the APJ Abdul Kalam Technological
University, Kerala is a bonafide work done by me under supervision of Ms. Anu K S .
This submission represents my ideas in my own words and where ideas or words
of others have been included, I have adequately and accurately cited and referenced
the original sources.
I also declare that I have adhered to ethics of academic honesty and integrity
and have not misrepresented or fabricated any data or idea or fact or source in my
submission. I understand that any violation of the above will be a cause for disciplinary
action by the institute and/or the University and can also evoke penal action from the
sources which have thus not been properly cited or from whom proper permission has
not been obtained. This report has not been previously formed the basis for the award
of any degree, diploma or similar title of any other University.
07-10-2024
Abstract
The increasing integration of Internet of Things (IoT) and Machine Learning (ML)
in healthcare has revolutionized real-time health monitoring and illness prediction.
This report explores the development of an IoT-based Illness Prediction System
that utilizes wearable devices to continuously track vital health data such as blood
pressure, pulse rate, and glucose levels. By employing K-Nearest Neighbor (KNN)
and Support Vector Machine (SVM) algorithms, the system processes the collected
data to predict potential health risks and provide preventive care. The proposed
framework focuses on data preprocessing, classification, and real-time analysis to
enhance the accuracy of predictions. The system has the potential to reduce healthcare
costs, improve early detection of illnesses, and optimize workplace health monitoring.
Evaluation metrics such as accuracy, precision, and recall were used to assess the
performance of the algorithms, demonstrating their effectiveness in classifying health
data. This report also outlines the challenges, benefits, and future scope of the system,
which includes enhancing sensor accuracy and incorporating advanced AI techniques
for better predictive outcomes.
i
Acknowledgement
I take this opportunity to express my deepest sense of gratitude and sincere thanks
to everyone who helped me to complete this work successfully. I would remember
with grateful appreciation, the encouragement and support rendered by Dr. Sobha P,
Principal, Eranad Knowledge City, Manjeri. I express my sincere thanks to Ms Anu
K S, Head of Department, Computer Science and Engineering, Eranad Knowledge
City Technical Campus Manjeri for providing me with all the necessary facilities and
support.
I would like to express my sincere gratitude to Ms. Shyni. and depart-
ment of Computer Science and Engineering, Eranad Knowledge City Technical
Campus Manjeri for their support and co-operation.
I would like to place on record my sincere gratitude to my seminar guide
Ms. Anu K S , HOD of department of Computer Science and Engineering, Eranad
Knowledge City Technical Campus for the guidance and mentorship throughout the
course.
Finally I thank my family, and friends who contributed to the successful fulfilment
of this seminar work.
Faiz
ii
Contents
Abstract i
Acknowledgement ii
List of Figures v
1 Introduction 1
2 Literature Survey 2
2.1 A Novel Machine Learning Technique for Diabetic Prediction in IoT-
based Healthcare Monitoring System . . . . . . . . . . . . . . . . . 3
2.1.1 Methodology: . . . . . . . . . . . . . . . . . . . . . . . . . . 3
2.1.2 Advantages: . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
2.1.3 Disadvantages: . . . . . . . . . . . . . . . . . . . . . . . . . 3
2.2 Health Disease Prediction Using Machine Learning and Internet of
Things . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
2.2.1 Methodology: . . . . . . . . . . . . . . . . . . . . . . . . . . 4
2.2.2 Advantages: . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
2.2.3 Disadvantages: . . . . . . . . . . . . . . . . . . . . . . . . . 4
2.3 Intelligent IoT-based Combined Crop-type and Disease Prediction
System with Machine Learning . . . . . . . . . . . . . . . . . . . . 4
2.3.1 Methodology: . . . . . . . . . . . . . . . . . . . . . . . . . . 4
2.3.2 Advantages: . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
2.3.3 Disadvantages: . . . . . . . . . . . . . . . . . . . . . . . . . 5
2.4 Improved IoT for Health Behaviour System Based on Machine Learn-
ing Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
iii
2.4.1 Methodology: . . . . . . . . . . . . . . . . . . . . . . . . . . 5
2.4.2 Advantages: . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
2.4.3 Disadvantages: . . . . . . . . . . . . . . . . . . . . . . . . . 5
3 Proposed System 6
3.1 Machine Learning Framework . . . . . . . . . . . . . . . . . . . . . 6
3.1.1 Data Segmentation: . . . . . . . . . . . . . . . . . . . . . . . 6
3.1.2 Dimensionality Reduction: . . . . . . . . . . . . . . . . . . . 7
3.1.3 Supervised Learning Approach: . . . . . . . . . . . . . . . . 7
3.2 Data Collection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
3.2.1 Loading and Preprocessing: . . . . . . . . . . . . . . . . . . 8
3.3 Data Preprocessing and Feature Engineering . . . . . . . . . . . . . . 8
3.4 K-Nearest Neighbor (KNN) . . . . . . . . . . . . . . . . . . . . . . 9
3.4.1 Key Features of KNN: . . . . . . . . . . . . . . . . . . . . . 9
3.4.2 How KNN Works in Illness Prediction: . . . . . . . . . . . . 10
3.4.3 Advantages of KNN: . . . . . . . . . . . . . . . . . . . . . . 10
3.4.4 Disadvantages of KNN: . . . . . . . . . . . . . . . . . . . . 10
3.5 Support Vector Machine (SVM) . . . . . . . . . . . . . . . . . . . . 11
3.5.1 Key Features of SVM: . . . . . . . . . . . . . . . . . . . . . 11
3.5.2 How KSVM Works in Illness Prediction: . . . . . . . . . . . 11
3.5.3 Advantages of SVM: . . . . . . . . . . . . . . . . . . . . . . 11
3.5.4 Disadvantages of SVM: . . . . . . . . . . . . . . . . . . . . 12
References 16
iv
List of Figures
4.1 Dataset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
4.2 Relevant Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
v
Chapter 1
Introduction
1
Chapter 2
Literature Survey
2
2.1 A Novel Machine Learning Technique for Dia-
betic Prediction in IoT-based Healthcare Monitor-
ing System
Authors: Dr. S. Aravinth Vijay Jesuraj, M. Sridharan, R. Ganesh, Dr. Vivek
Ravishankar Dubey, Vinda Manjramkar
This study introduces the development of a system that uses Tuna Swarm
Optimization-Aided Neural Classifier (TSO-NN) for diabetes prediction. The
system utilizes IoT-based wearable devices to collect patient data such as glucose levels
and processes the data through ML techniques. The model’s performance is evaluated
based on accuracy, precision, and sensitivity.
• 2.1.1 Methodology:
Data is gathered from wearable sensors and classified using a neural network
enhanced by optimization techniques. Metrics like F1-score are used for
evaluation.
• 2.1.2 Advantages:
• 2.1.3 Disadvantages:
3
This paper discusses the use of IoT for disease prediction. Decision Trees, KNN,
and Naı̈ve Bayes algorithms are applied to health data collected from IoT devices for
early detection of diseases. The system is designed for real-time data processing using
cloud and fog computing.
• 2.2.1 Methodology:
IoT devices collect health data, which is processed in the cloud for real-time
predictions using ML classifiers.
• 2.2.2 Advantages:
• 2.2.3 Disadvantages:
• 2.3.1 Methodology:
4
• 2.3.2 Advantages:
• 2.3.3 Disadvantages:
• 2.4.1 Methodology:
Multiple layers of ML algorithms are used to classify health behavior data with
a focus on accuracy and precision.
• 2.4.2 Advantages:
• 2.4.3 Disadvantages:
5
Chapter 3
Proposed System
The data collected from wearables are divided into training and testing datasets.
Training data is used to develop the model by teaching the algorithm to recognize
patterns, while testing data is used to validate the model’s accuracy. Splitting data
ensures that the model generalizes well and performs accurately on unseen data.
6
Figure 3.1: System Architecture
Given that health data can include numerous parameters (such as blood pressure,
glucose levels, pulse rate, etc.), dimensionality reduction techniques are applied to
optimize performance. This process involves reducing the complexity of the dataset
by eliminating irrelevant or redundant features, which in turn improves the efficiency
and accuracy of ML algorithms.
The system employs supervised learning, where the input data (e.g., health parameters)
is labeled with output categories (e.g., healthy or unhealthy conditions). Supervised
learning is advantageous because the algorithms learn from labeled data and make
more precise predictions.
7
3.2 Data Collection
Wearable Devices play a critical role in the IoT-based health monitoring system.
These devices collect a wide range of physiological data from users, including:
• Pulse Rate: Tracks heart rate over time to identify abnormal heart rhythms or
early signs of cardiovascular issues.
The data is transmitted wirelessly from the wearable devices to a central server or
cloud platform, where it is stored, processed, and analyzed using the machine learning
framework.
8
Figure 3.2: Loading and Preprocessing
9
data point (new reading) and previous data points (labeled readings). The
algorithm looks for the closest points to the new data.
1. The system receives new health data (e.g., a person’s current blood pressure and
pulse rate).
2. It compares this new data to the historical dataset (labeled with healthy or
unhealthy conditions).
3. Based on the closest matching data points, the algorithm predicts whether the
person is at risk of illness (e.g., hypertension or heart disease).
• Computationally Intensive: As the size of the dataset grows, the time required
to find the nearest neighbors increases.
10
3.5 Support Vector Machine (SVM)
Support Vector Machine (SVM) is a supervised learning algorithm that is com-
monly used for classification tasks in the healthcare domain due to its high perfor-
mance in handling complex and high-dimensional data.
• Maximizing Margin: The algorithm aims to find the widest possible margin
between the two classes. This margin is the distance between the hyperplane and
the closest data points from each class, known as support vectors.
1. The system receives health data from wearable devices (e.g., temperature,
glucose levels).
2. The SVM algorithm constructs a hyperplane that best separates healthy individ-
uals from those at risk of illness.
3. If the new data point falls on one side of the hyperplane, the system classifies it
as ‘healthy’; if it falls on the other side, it is classified as ‘unhealthy’ or at risk.
• High Accuracy: SVM is known for its ability to perform well in high-
dimensional spaces and deliver precise predictions.
11
• Effective with Small Datasets: It works well even when the dataset is not very
large, making it suitable for healthcare settings where data collection might be
limited.
12
Chapter 4
• Precision: Measures the accuracy of the positive predictions made by the model
(e.g., how many individuals predicted to have an illness actually have it).
• Recall: Measures the model’s ability to identify all positive cases (e.g., how
many individuals who have an illness were correctly identified).
By using these metrics, the system ensures that the predictions made by the KNN and
SVM algorithms are reliable and actionable for healthcare providers and individuals.
The performance of the proposed system was evaluated based on the accuracy of
the KNN and SVM algorithms. The results showed that both algorithms performed
well in classifying health data, with SVM showing slightly higher accuracy due to
its ability to handle high-dimensional data more efficiently. The system successfully
demonstrated the potential for early illness detection and preventive care through
continuous monitoring.
13
Figure 4.1: Dataset
14
Chapter 5
In conclusion, the IoT-based illness prediction system using machine learning offers
a promising solution for real-time health monitoring in workplace environments. The
integration of wearable devices with ML algorithms like KNN and SVM allows for
early illness detection and preventive care, reducing medical leave and healthcare costs.
Future Scope:
15
References
3. Md. Ishan Arefin Hossain, Syeda Mahin Binta Haque, ”Intelligent IoT-based
Combined Crop-type and Disease Prediction System with Different Machine
Learning Techniques,” 2023.
4. Dr. Anurag Shrivastava, Dr. Midhun Chakkaravarthy, et al., ”Improved IoT for
Health Behaviour System Based on Machine Learning Model,” 2022.
7. Khan Y, Ostfeld AE, Lochner CM, Pierre A, Arias AC. “Monitoring of vital
signs with flexible and wearable medical devices,” Advanced Materials, vol. 28,
no. 22, pp. 4373-4395, 2016.
16
9. S. Seneviratne, Y. Hu, T. Nguyen et al., “A survey of wearable devices and
challenges,” IEEE Communications Surveys & Tutorials, vol. 19, no. 4, pp.
2573-2620, 2017.
11. S. S. Kale and D. Bhagwat, “Highly secured IoT-based healthcare system for
elderly people using body sensor network,” International Journal of Innovative
Research in Science Engineering and Technology, vol. 5, no. 10, 2016.
12. N. Hussain, “IEEE 802.15.6 standard in wireless body area networks from a
healthcare point of view,” IEEE Sensors Journal, vol. 16, no. 5, pp. 1368-1376,
2016.
17