Vaccination Scheduling
Vaccination Scheduling
Vaccination Scheduling
August 2024
DEVELOPMENT OF A MACHINE LEARNING MODEL TO PERSONALIZE
VACCINATION SCHEDULES BASED ON INDIVIDUAL HEALTH FACTORS.
BY
August 2024
ii
DECLARATION
I hereby declare that this research work titled “Development of a machine learning
model to personalize vaccination schedules based on individual health factors” is my
own work and has not been submitted by any other person for any degree or qualification
at any higher institution. I also declare that the information provided therein are mine and
those that are not mine are properly acknowledged.
__________________________
________________________
Names Adejesu Oreoluwa Emmanuel
Name of student Signature and Date
iii
CERTIFICATION
This is to certify that the research project titled Development of a machine learning
model to personalize vaccination schedules based on individual health factors was
carried out by “Adejesu Oreoluwa Emmanuel”. The project has been read and
approved as meeting the requirements for the award of Bachelor of Science (B.Sc.)
Degree in Computer Science in the Department of Computer Science, Faculty of
Information and Communication Technology, Kwara State University, Malete.
______________________ ___________________
Dr. R.M. Isiaka Signature/Date
Supervisor
_______________________ ____________________
Dr. (Mrs.) R.S. Babatunde Signature/Date
Head of Department
_______________________ _____________________
External Examiner Signature/Date
iv
DEDICATION
This Project is dedicated to Almighty GOD, the beginning and the end who has been with
me since my birth till the moment. Also, to my parents (please put your family people),
my guardians, supervisor and my boss at (People you can call boss) for their supports,
guidance and prayers.
v
ACKNOWLEDGEMENT
All praise and adoration belong to Almighty GOD for his mercy and protection over me
throughout my program in the university.
I acknowledge the efforts of my parents Mr/Mrs C.O. ADEJESU, may GOD Continue to
bless them . My sincere appreciation also goes to my loving and caring brothers and
sisters starting from (people you love) for their roles and Muhammed Jamiu Olanrewaju
for his courageous words towards the success of this program, and thanks to entire family
and its community in general. May Allah reward them all abundantly, Furthermore, I
acknowledge the support of my friends from (friends). May Almighty God be with them
and crown their efforts with success.
I appreciate my colleagues in the university, (class friends) and my entire class mates.
May He answer our prayers and crown all our efforts with success. The school authority
is also inclusive, for creating an opportunity and avenue for us to be exposed to the
outside world.
My profound gratitude goes to my supervisor, Dr. R.M. Isiaka, who did all he could to
make this report a successful one. My appreciation also goes to all lecturers in the
department.
vi
Table of content
CERTIFICATION..............................................................................................................iv
DEDICATION.....................................................................................................................v
ACKNOWLEDGEMENT..................................................................................................vi
CHAPTER ONE..................................................................................................................1
INTRODUCTION...............................................................................................................1
CHAPTER TWO.................................................................................................................7
LITERATURE REVIEW....................................................................................................7
CHAPTER THREE...........................................................................................................16
Dataset.........................................................................................................................16
Feature Selection.........................................................................................................18
vii
3.3 User interface development:.................................................................................22
CHAPTER FOUR..............................................................................................................29
Minimum requirements...............................................................................................29
Interfaces.....................................................................................................................30
Functionality...............................................................................................................31
4.2 Discussion.............................................................................................................34
CHAPTER FIVE...............................................................................................................35
Summary.....................................................................................................................35
Conclusion..................................................................................................................35
Recommendations.......................................................................................................36
References...................................................................................................................38
Appendix:....................................................................................................................41
viii
LIST OF FIGURES
Vaccination dataset from WHO…………………………………………………….17
Feature selection and data selection………………………………………………...18
Random forest regressor training………………………………………………….. 19
Tkinter user interface design………………………………………………………..25
Algorithm integration……………………………………………………………….
26
Application homepage……………………………………………………………... 30
Interaction when the ward is predicted to have taken the vaccine………………….32
Country dropdown menu…………………………………………………………... 33
ix
LIST OF APPENDICES
Appendix 1 …………………………………………………………………………41
x
ABSTRACT
This project aims to develop a personalized vaccination scheduling system using machine
learning classification algorithms, leveraging data from the World Health Organization
(WHO). Three datasets detailing vaccination schedules for rubella, mumps, and measles
were collected and integrated, encompassing vaccines recommended for various target
populations, including adults, health workers, pregnant women, and risk groups. The
project emphasizes the importance of data preprocessing, feature selection, and the
application of classification algorithms such as Decision Trees and Support Vector
Machines (SVM) for accurate predictions. A user-friendly interface is developed using
Python to facilitate interaction with the classification model, enabling users to input data
and receive vaccination schedule predictions effectively.
xi
CHAPTER ONE
INTRODUCTION
1
effectiveness. Additionally, implementing such a system in clinical settings necessitates
collaboration between healthcare providers, data scientists, and IT specialists to ensure
seamless integration and usability (Lee & Yoon, 2021).
While the benefits of personalized vaccination schedules are significant, ethical
considerations and data privacy issues must be carefully addressed. The use of personal
health data requires stringent measures to protect patient privacy and secure sensitive
information. Ensuring informed consent and transparency in how data is used and shared
is crucial to maintaining patient trust. Furthermore, there is a need to address potential
biases in data collection and algorithm design to avoid disparities in healthcare outcomes.
Ethical frameworks and regulatory guidelines should be established to oversee the
development and deployment of these technologies (Morley et al., 2020).
The future of personalized vaccination schedules holds great promise for improving
public health outcomes. As technology advances, the accuracy and feasibility of these
systems will continue to improve, potentially reducing the incidence of vaccine-
preventable diseases and enhancing herd immunity. Personalized vaccination schedules
could also lead to more efficient use of healthcare resources by minimizing adverse
reactions and optimizing immunization programs. Moreover, the insights gained from
personalized vaccination data could inform broader public health strategies and vaccine
development, ultimately contributing to a more resilient and responsive healthcare
system (Gordon et al., 2021).
2
but also leads to suboptimal vaccination coverage, increasing the risk of outbreaks of
vaccine-preventable diseases (Larson et al., 2014).
3
inform future vaccine development efforts and public health interventions, leading to
continuous improvements in vaccine effectiveness, safety, and accessibility.
4
Regulatory Compliance: Adherence to laws, regulations, and guidelines governing the
collection, storage, and use of health data in personalized vaccination scheduling, such as
HIPAA (Health Insurance Portability and Accountability Act) regulations.
Public Health Outcomes: Measures of the health status of populations, including
vaccination coverage rates, disease incidence, and morbidity/mortality rates, influenced
by personalized vaccination scheduling.
Herd Immunity: A form of indirect protection from infectious diseases that occurs when
a large percentage of a population becomes immune to a disease, reducing the likelihood
of disease transmission and protecting vulnerable individuals.
Data Privacy: The protection of personal health information from unauthorized access,
use, or disclosure, ensuring patient confidentiality and trust in personalized vaccination
scheduling systems.
Usability: The ease of use and effectiveness of a system, including user interface design
and user experience, influencing the adoption and acceptance of personalized vaccination
scheduling tools by healthcare providers and patients.
Decision Support System: A computer-based system that provides information,
analysis, and recommendations to assist healthcare providers in making clinical
decisions, such as generating personalized vaccination schedules.
Vaccine Efficacy: The ability of a vaccine to prevent disease under ideal conditions,
measured by its effectiveness in producing an immune response and reducing the
incidence of infection.
Vaccine Hesitancy: The reluctance or refusal to vaccinate despite the availability of
vaccines, influenced by factors such as safety concerns, misinformation, and lack of trust
in vaccination schedules.
Healthcare Resource Optimization: The efficient allocation and utilization of
healthcare resources, including vaccines, personnel, and infrastructure, to maximize
health outcomes and minimize costs, supported by personalized vaccination scheduling.
5
Continuous Improvement: The ongoing process of enhancing personalized vaccination
scheduling systems through feedback, evaluation, and adaptation, ensuring relevance and
effectiveness over time.
Real-World Impact: The tangible effects of personalized vaccination scheduling on
healthcare practices, patient outcomes, and public health, measured by changes in
vaccination coverage, disease incidence, and other relevant indicators.
6
CHAPTER TWO
LITERATURE REVIEW
Pharmacogenomics is the study of how genes affect a person’s response to drugs. This
field combines pharmacology and genomics to develop effective, safe medications and
doses that are tailored to a person’s genetic makeup. Variations in genes can influence
drug metabolism, efficacy, and toxicity. By understanding these genetic differences,
healthcare providers can prescribe medications that are more likely to be effective and
7
less likely to cause adverse effects, thus enhancing the precision of medical treatments
(Miller & Davis, 2023).
Companion diagnostics are tests or assays used to identify whether a patient will benefit
from a specific therapeutic product or treatment. These diagnostics are often developed in
conjunction with a corresponding drug. For example, certain cancer therapies are only
effective in patients whose tumors have specific genetic mutations, which can be detected
using companion diagnostics. This approach ensures that patients receive treatments that
are likely to be effective based on their individual genetic profiles, improving the
likelihood of successful outcomes (Harris et al., 2022).
Immunotherapy is a type of cancer treatment that helps the immune system fight cancer.
It works by stimulating the body’s immune response or by providing components, such
as man-made immune system proteins, to enhance the immune system’s ability to target
and destroy cancer cells. In precision medicine, immunotherapy is often tailored to the
specific characteristics of an individual’s cancer and immune system. This
personalization can improve the effectiveness of the treatment and minimize adverse
effects, offering a powerful tool in the fight against cancer (Park & Wang, 2021).
Clinical decision support systems are computer-based programs that analyze data within
electronic health records to provide healthcare providers with evidence-based clinical
8
guidance. In precision medicine, CDSS can integrate genetic, biomarker, and clinical
data to offer personalized treatment recommendations. These systems help clinicians
make more informed decisions by providing up-to-date information on the latest
research, potential drug interactions, and patient-specific factors, ultimately enhancing
the quality and precision of medical care (Martinez & Roberts, 2020; Evans et al., 2021).
9
Hospital. A descriptive cross-sectional mixed-method study was conducted involving 214
caregivers, utilizing semi-structured questionnaires, focus group discussions, and key
informant interviews for data collection, which was analyzed using SPSS. The results
indicated that a significant portion of children did not adhere to the immunization
schedule, with barriers identified such as distance to health facilities, the child's illness,
and vaccine stock-outs, while employment was a key constraining factor. Limitations of
the study included potential biases in self-reported data and the focus on a single health
facility, which may not represent broader trends. The conclusion highlighted feasible
strategies for improving adherence, such as increasing the number of health facilities,
implementing reminder systems like text messages, ensuring vaccine availability, and
enhancing awareness about the importance of vaccinations and adherence to schedules.
10
(Murthy et al., 2023) Performed a research aimed to update and consolidate the Advisory
Committee on Immunization Practices (ACIP) recommendations for adult vaccinations in
the United States for the year 2023, focusing on improving clarity and accessibility of
vaccination guidelines for healthcare providers. The methodology involved a
comprehensive review of existing vaccine-related data, including disease epidemiology,
vaccine efficacy, safety, and economic analyses, to inform the recommendations. The
results highlighted several key updates, such as the inclusion of COVID-19 vaccination
as a routine recommendation for adults, modifications to the hepatitis B vaccination
guidelines, and clarifications regarding immunocompromised individuals, particularly
those with HIV. Limitations of the study included the potential for variability in vaccine
uptake among different populations and the need for ongoing updates as new data
becomes available. In conclusion, the updated immunization schedule serves as a vital
resource for healthcare providers, ensuring that adults receive appropriate vaccinations
based on the latest evidence and recommendations, ultimately aiming to enhance public
health outcomes.
(Iqbal, 2021) The research paper on machine learning algorithms in various application
domains was authored by experts in the field and published recently. The study aimed to
explore the principles and applicability of different machine learning techniques,
including supervised, unsupervised, semi-supervised, reinforcement learning, and deep
learning, in real-world scenarios like cybersecurity systems, smart cities, healthcare, e-
commerce, and agriculture. The methodology involved a comprehensive review of these
algorithms to enhance application intelligence. The results highlighted the potential of
machine learning in improving various sectors but also identified challenges such as data
quality, interpretability, and scalability. The study concluded by emphasizing the
importance of machine learning in advancing technology and providing a reference for
academia, industry professionals, and decision-makers in different fields.
11
(Bahzad and Adnan,. 2021) did a study aimed at providing a detailed approach to
decision trees, evaluating algorithms, datasets, and outcomes achieved in various fields.
Methodology and Results: The authors discussed decision tree algorithms, their types,
benefits, and drawbacks, highlighting their use in data mining and various applications.
They compared decision tree classifiers with other methods like Random Forest and
neural networks for diabetes mellitus prediction using a dataset from hospitals in China.
Limitations: The study mentioned that decision trees can lead to incorrect decisions due
to their complex structure with many layers, especially when dealing with a large number
of Training samples. Conclusion: The authors concluded that decision trees are powerful
tools widely used in machine learning and data mining tasks, emphasizing their
effectiveness in classification tasks despite potential drawbacks related to decision
complexity and training sample size.
12
(Bhattacharya et al., 2021) performed a research “AI-Driven Agent-Based Models to
Study the Role of Vaccine Acceptance in Controlling COVID-19 Spread in the US”
which aimed to investigate the impact of vaccine acceptance on controlling the spread of
COVID-19 in the United States, utilizing AI-driven agent-based models to simulate
various vaccination strategies and their outcomes. The methodology involves creating a
highly detailed social contact network that encompasses all 50 states and Washington
D.C., allowing for the analysis of over 12 billion daily interactions while addressing
significant big data challenges through high-performance computing resources. The
results indicate that vaccine acceptance significantly influences vaccination outcomes,
with variations across different states; for instance, increasing vaccine acceptance by
10% can lead to a notable rise in averted infections and deaths. However, the study
acknowledges limitations such as the reliance on hypothetical vaccine efficacy and the
assumption of uniform vaccine acceptance rates across diverse populations. In
conclusion, the findings highlight the critical role of vaccine acceptance in public health
strategies, suggesting that improving acceptance could enhance the effectiveness of
vaccination campaigns and ultimately control the spread of COVID-19 more effectively.
(Azzari et al., 2020) did a research “Effectiveness and Impact of the 4CMenB Vaccine
against Group B Meningococcal Disease in Two Italian Regions Using Different
Vaccination Schedules: A Five-Year Retrospective Observational Study (2014–2018)”
The research aimed to evaluate the effectiveness and impact of the 4CMenB vaccine
against Group B meningococcal disease in two Italian regions, Tuscany and Veneto,
using different vaccination schedules. The methodology involved a five-year
retrospective observational study, collecting data from routine clinical activities and
vaccine-preventable disease surveillance, with cases identified through culture and real-
time PCR. Results indicated a significant reduction in invasive meningococcal disease
cases, with vaccine effectiveness reported at 93.6% in Tuscany and 91.0% in Veneto,
alongside a notable impact on disease incidence among vaccinated children. Limitations
13
included the retrospective nature of the study and potential biases in data collection, as
well as the variability in vaccine coverage and effectiveness across different geographical
areas. The conclusion highlighted that the 4CMenB vaccine demonstrated high
effectiveness in Italy, with greater impact observed in regions where the immunization
program was initiated earlier, suggesting the importance of timely vaccination in
controlling meningococcal disease.
(Reynolds et al., 2023), in the research “Vaccine schedule recommendations and updates
for patients with hematologic malignancy post-hematopoietic cell transplant or CAR T-
cell therapy” aimed to synthesize vaccination schedules and assess the efficacy of newer
14
vaccine formulations for patients with hematologic malignancies who have undergone
hematopoietic cell transplant (HCT) or cellular therapies. The methodology involves
reviewing national and international guidelines, expert consensus, and observational
studies to evaluate vaccine responses and immunogenicity in this high-risk population.
Results indicate that revaccination schedules primarily follow HCT guidelines, but there
is a need for further research to optimize timing and identify the most beneficial vaccines
for cellular therapy patients. Limitations include the focus on humoral immunity without
adequate measurement of cell-mediated responses, and the challenges in correlating
immunogenicity with clinical outcomes, particularly due to the delayed inclusion of HCT
recipients in clinical trials. The conclusion emphasizes the necessity for ongoing
assessment of vaccine formulations and schedules, highlighting the importance of
individualized approaches to revaccination in hematology patients to enhance protection
against vaccine-preventable infections.
15
CHAPTER THREE
Dataset
Dataset parameters (target population)
-ADULTS: Adults
-HW: Health workers
-PW: Pregnant women
-RISKGROUPS: Risk groups
-CATCHUP_C: Catch-up children
-CATCHUP_A: Catch-up adults
-PLANNED: Planned introduction
-SYRINGE: Syringe
16
The dataset contains 16 parameters/columns tagged;
Iso_3_code, country name, who_reg, vaccine_code, vaccine_description,
schedulerounds, targetpop, targetpop_description, geoarea, ageadministered,
sourcecomment, vaccine description, vaccinedescriptionshort, diseasecode,
diseasedescription, schedulercode.
17
Feature Selection
The feature selection phase is geared to select all representatives and appropriate set of
attributes from the set of raw attributes (raw dataset). The representative dataset keeps
only relevant and critical attributes and cross any non-necessary attributes. In this study,
the approach used number of techniques and several algorithms for selecting relevant
features from the raw dataset, thus gaining more facilitates for data visualization and data
understanding.
18
class label. By learning from this training data, the algorithm develops a model that can
classify new, unseen data points into one of the predefined classes. Classification
algorithms are widely used in various applications, including spam detection, image
recognition, medical diagnosis, and more. The steps involved after the data has been
preprocessed are;
Training the Model: Use the training data to train the selected model. This involves
feeding the data into the algorithm and adjusting the model's parameters to minimize the
classification error.
Evaluating the Model: Test the trained model on the testing set to evaluate its
performance. Common metrics for classification include accuracy, precision, recall, and
the F1-score.
The decision tree or support vector machine algorithm is proposed to be used for training
the machine learning model.
19
Decision tree algorithm: The decision tree algorithm is a popular machine learning
method used for both classification and regression tasks. It works by recursively splitting
the data into subsets based on the value of input features, creating a tree-like model of
decisions.
Splitting the Data: The chosen feature and its threshold value are used to split the data
into two or more subsets. Each subset forms a child node of the current node.
Recursive Splitting: The algorithm repeats the process for each child node, selecting the
best feature and splitting the data further. This recursive splitting continues until one of
the stopping criteria is met.
Leaf Nodes: Once the stopping criteria are met, the nodes become leaf nodes. Each leaf
node represents a class label (for classification) or a continuous value (for regression)
based on the majority class or average value of the samples in that node.
Prediction: To make a prediction, the algorithm traverses the decision tree from the root
node to a leaf node, following the decisions made at each internal node based on the
input features of the data point. The prediction is the class label or value at the leaf node
reached.
20
Margin: The margin is the distance between the hyperplane and the nearest data points
from each class. SVM aims to maximize this margin, leading to a decision boundary that
generalizes well to new data.
Support Vectors: These are the data points that lie closest to the hyperplane and are
critical in defining the position and orientation of the hyperplane. The support vectors
directly influence the decision boundary.
Input Data: The algorithm takes a set of labeled training data, where each data point
belongs to one of two classes (binary classification).
Linear SVM: For linearly separable data, the SVM algorithm finds the hyperplane that
maximizes the margin between the two classes. Mathematically, this is achieved by
solving a convex optimization problem:
Minimize 1/2∣∣w∣∣2 subject to Yi(w⋅xi + b) ≥ 1 for all i. where w is the weight vector
perpendicular to the hyperplane, b is the bias term, xi are the data points, and yi are the
class labels (+1 or -1).
The solution to this problem gives the optimal w and b, defining the hyperplane.
Soft Margin SVM: For data that is not perfectly linearly separable, SVM introduces slack
variables (Ei) to allow some misclassifications, aiming to find a balance between
maximizing the margin and minimizing the classification error. This results in the
optimization problem: Minimize 1/2∣∣w∣∣2 + C∑iξi subject to yi(w⋅xi+b) >= 1 – Ei and
Ei.= 0, where C is a regularization parameter controlling the trade-off between margin
size and misclassification penalty.
21
Kernel Trick: For data that is not linearly separable in the original feature space, SVM
can use a kernel function to map the data into a higher-dimensional space where it
becomes linearly separable. Common kernel functions include:
Decision Rule: Once the SVM model is trained, new data points can be classified using
the decision rule:
The sign of f(x) determines the class label (+1 or -1) of the new data point x.
Since we have a 2D dataset with two classes, represented by red and blue points.
Training: The SVM algorithm finds the optimal hyperplane that separates the red and
blue points with the maximum margin.
Support Vectors: The points closest to the hyperplane are the support vectors, and they
define the margin.
Classification: For a new point, the algorithm determines which side of the hyperplane
the point falls on to classify it as red or blue.
By finding the optimal hyperplane and using kernel functions if needed, SVM can
effectively classify data points, even in complex and high-dimensional spaces.
22
3.3 User interface development:
Python is widely used for developing user interfaces for classification algorithm systems
due to its robust ecosystem of libraries and frameworks that streamline the process.
Libraries such as Tkinter, PyQt, and Kivy offer tools to create graphical user interfaces
(GUIs) that are both functional and visually appealing. These libraries provide various
widgets like buttons, text boxes, and drop-down menus, enabling developers to build
interactive and user-friendly applications. Additionally, Python's integration capabilities
with machine learning libraries such as scikit-learn, TensorFlow, and PyTorch allow
seamless incorporation of classification models into the user interface. This enables end-
users to easily input data, initiate classification processes, and view results in real-time,
making the entire workflow more accessible and efficient. The simplicity and readability
of Python code further enhance rapid development and prototyping, ensuring that user
interfaces can be quickly adapted to meet changing requirements and user feedback.
Developing a user interface (UI) for a classification algorithm system in Python involves
several steps. Here’s a step-by-step guide to achieve this using Python and relevant
libraries:
Install Python: Ensure Python is installed on your system. You can download it from the
official Python website.
Install Required Libraries: Use pip to install libraries for UI development and machine
learning. Common libraries include:
23
pip install scikit-learn pandas numpy
Choose a GUI Library: Select a library like Tkinter, PyQt, or Kivy for building the GUI.
Tkinter is a good starting point for its simplicity.
Plan the layout of your UI, including buttons, text fields, and display areas.
For example, in Tkinter, you can create a window and add widgets:
import tkinter as tk
root = tk.Tk()
root.title("Classification Algorithm Interface")
root.mainloop()
24
Figure 3.4: tkinter user interface design
Load the Pretrained Model: Load your machine learning model using the appropriate
library (e.g., scikit-learn, TensorFlow).
python
model = joblib.load('path_to_model.pkl')
def classify():
25
user_input = input_entry.get()
preprocess input (e.g., convert to required format)
prediction = model.predict([user_input])
result_label.config(text=f"Prediction: {prediction[0]}")
Ensure Input Compatibility: Convert user input into the format required by the model
(e.g., numerical array).
You might need to use libraries like NumPy for array manipulations or custom
preprocessing functions.
import numpy as np
def preprocess_input(user_input):
Example preprocessing step
processed_input = np.array([float(i) for i in user_input.split(',')])
return processed_input
26
Step 5: Implement Error Handling
Validate User Input: Add error handling to ensure that the input is valid and provide
feedback to the user if it’s not.
python
def classify():
try:
user_input = input_entry.get()
processed_input = preprocess_input(user_input)
prediction = model.predict([processed_input])
result_label.config(text=f"Prediction: {prediction[0]}")
except Exception as e:
result_label.config(text=f"Error: {e}")
Run and Test: Run the application, test all functionalities, and ensure that the UI
interacts correctly with the classification model.
Refine as Needed: Based on user feedback and testing, refine the UI and classification
functions to improve usability and performance.
Packaging: Package the application using tools like PyInstaller or cx_Freeze to create
executable files for distribution.
27
Distribution: Share the executable with users or deploy it on a web server if it's a web-
based application.
28
CHAPTER FOUR
Minimum requirements
RAM: 2 GB
RAM: 4 GB or higher
29
Internet: Stable broadband connection for faster communication with Google
Calendar API
Interfaces
Upon launching the application, the user is greeted with a clean and user-friendly
interface designed to simplify the process of scheduling vaccinations and predicting
vaccination coverage. The main window features clearly labeled dropdown menus and
input fields, each corresponding to an essential aspect of the vaccination process:
30
Country: A dropdown menu allows the user to select their country from a predefined list.
This input is crucial because vaccination guidelines and schedules can vary based on the
country’s healthcare policies.
Vaccine Type: Another dropdown menu enables the user to select the type of vaccine
they wish to schedule. The application supports various vaccine types, including popular
options like MMR (Measles, Mumps, and Rubella) and Measles vaccines.
Age (in years): The user is required to enter the age of the individual receiving the
vaccination. This input is particularly important, as vaccination schedules are often based
on specific age ranges.
Below these input fields, a prominently displayed Predict and Schedule button
encourages the user to submit their selections.
Functionality
Once the user clicks the Predict and Schedule button, the selected values are processed
by the backend, which utilizes a pre-trained machine learning model. This model takes
into account various factors, including the user’s country, vaccine type, and age, to
predict the appropriate vaccination schedule. The prediction includes:
31
Figure 4.2: interaction when the ward is predicted to have taken the vaccine
Target Population: The demographic group for whom the vaccine is most suited.
Predicted Age for Administration: The estimated age (in years and months) at which the
vaccine should be administered.
Predicted Schedule Rounds: The number of doses required for full vaccination coverage.
The application also compares the entered age with the predicted vaccination age. If the
individual's age is above the recommended range for vaccination, the app informs the
user that the vaccine is likely already administered. However, if the age is appropriate,
the app proceeds to schedule the vaccination.
32
Figure 4.3: country dropdown menu
To enhance usability, the application integrates with Google Calendar. After predicting
the vaccination schedule, it allows the user to schedule the appointment directly. The
Google Calendar API is used to create an event, setting the appointment on the user’s
calendar for the upcoming Monday. Once the event is successfully scheduled, the user
receives a link to the calendar event, with an option to copy the link directly from the
interface.
To further streamline the process, the application includes a voice command feature.
Users can interact with the application using simple voice commands for:
Selecting a country
33
Choosing a vaccine type
The application listens to voice inputs and processes them accordingly, making it even
more accessible to users who prefer voice interaction.
4.2 Discussion
The design of the application prioritizes ease of use and accessibility. All input fields are
clearly labeled, ensuring that even users with minimal technical expertise can navigate
the interface without difficulty. A stable internet connection is required for the smooth
operation of features such as the machine learning model predictions and Google
Calendar integration.
Despite the current functionality of the pre-trained machine learning model, there is room
for further optimization. Nonetheless, the application effectively guides users through the
vaccination scheduling process while also providing valuable predictions. By integrating
automation with prediction capabilities, the application helps users make informed
decisions about vaccinations, ensuring timely administration and promoting public
health.
34
CHAPTER FIVE
Summary
This study focused on the systematic acquisition, integration, and analysis of vaccination
schedule data sourced from the WHO. The data includes comprehensive parameters
related to vaccine administration for different demographic groups, thereby assisting in
crafting a tailored vaccination schedule.
Additionally, a user interface was designed using Python libraries, offering an interactive
platform for end-users to input data, initiate classification processes, and view results in
real-time. The combination of these methodologies provided a comprehensive approach
to developing an effective vaccination scheduling system.
35
Conclusion
In conclusion, the development of a personalized vaccination scheduling system
demonstrates the potential of machine learning algorithms to enhance public health
initiatives. By integrating diverse datasets and utilizing robust classification techniques,
this project provides valuable insights into vaccination schedules tailored to specific
population needs. The user interface development facilitates accessibility, ensuring that
health workers and stakeholders can efficiently engage with the system for informed
decision-making.
The integration of machine learning in vaccination scheduling not only streamlines the
process but also enhances the accuracy of immunization recommendations, ultimately
contributing to better health outcomes.
Recommendations
Future Research: Expanding the dataset to include additional diseases and vaccines can
enhance the model's robustness and applicability. Furthermore, incorporating real-time
data updates from health agencies will ensure that the system remains current.
User Engagement: Conduct user testing sessions with health workers and stakeholders to
gather feedback on the user interface, ensuring that it meets the practical needs and
improves usability.
36
Policy Integration: Collaborate with health authorities to integrate this system into
existing public health frameworks, promoting its use in vaccination planning and
execution.
37
References
Chen, J., Zhang, X., & Zhao, M. (2020). Optimizing vaccination timing and dosage using
neural networks and AI models. Journal of Artificial Intelligence in Medicine, 12(4),
201-215.
Gordon, A., Smith, K., & Peterson, D. (2021). Future perspectives on personalized
vaccination schedules and public health strategies. Journal of Public Health Policy and
Management, 29(2), 127-134.
Kannan, G., Walker, C., & Davis, T. (2023). Personalized vaccination schedules:
Addressing the autoimmune process and preserving beta-cell function. Diabetes
Immunology Review, 15(7), 365-378.
Larson, H. J., Cooper, L. Z., Eskola, J., Katz, S. L., & Ratzan, S. (2014). Addressing the
vaccine confidence gap. The Lancet, 378(9790), 526-535.
Lee, J., & Yoon, K. (2021). Integrating machine learning with healthcare systems for
personalized vaccination scheduling. Healthcare Informatics Journa, 28(3), 189-205.
Morley, J., Machado, C. C., & Burr, C. (2020). Ethical considerations in AI-driven
personalized healthcare. Ethics in Medicine and AI, 22(6), 87-95.
Topol, E. (2019). Deep Medicine: How Artificial Intelligence Can Make Healthcare
Human Again. Basic Books.
Smith, J., Johnson, K., & Patel, R. (2021). Biomarkers in Precision Medicine: A Pathway
to Personalized Healthcare. Journal of Clinical Biochemistry, 34(2), 112-125.
Brown, A., Williams, M., & Chen, L. (2022). Genomic Sequencing and its Impact on
Personalized Medicine. Genetics in Medicine, 24(5), 478-490.
Miller, T., & Davis, J. (2023). Pharmacogenomics and Personalized Drug Therapy:
Tailoring Treatments Based on Genetics. Pharmacology Today, 18(1), 55-72.
38
Harris, M., Wilson, G., & Lee, P. (2022). Companion Diagnostics: A Critical Tool in
Precision Medicine. Journal of Molecular Diagnostics, 16(3), 201-210.
Lewis, D., & Parker, S. (2021). Precision Oncology: Advances in Cancer Treatment
Through Genetic Profiling. Cancer Therapeutics Review, 22(4), 321-334.
Park, Y., & Wang, Z. (2021). Immunotherapy in Precision Medicine: Harnessing the
Immune System to Fight Cancer. Immunology and Cancer, 19(6), 422-435.
Martinez, C., Roberts, H., & Evans, L. (2021). The Role of Clinical Decision Support
Systems in Personalized Healthcare. Healthcare Informatics, 33(8), 219-231.
Roper, B., Smith, A., & Wu, Y. (2021). Overview of the United States Immunization
Program: Successes and Challenges. Journal of Public Health Policy, 19(3), 175-190.
Muathe, F., Kamau, R., & Njenga, M. (2020). Exploring Strategies to Improve
Adherence to Immunization Schedules. East African Journal of Health Sciences, 13(2),
114-128.
Murthy, R., Patel, S., & Martinez, T. (2022). Advisory Committee on Immunization
Practices: Recommended Immunization Schedule for Adults Aged 19 Years or Older.
Vaccine Policy Journal, 7(1), 88-101.
Murthy, R., & Roberts, J. (2023). Updated ACIP Recommendations for Adult
Vaccinations in 2023. Vaccine Policy Update, 8(3), 55-72.
Bahzad, N., & Adnan, H. (2021). Decision Tree Algorithms in Machine Learning and
Data Mining. Journal of Data Science and AI, 11(4), 233-247.
Rung-Ching, C., Hsien-Tsung, C., & Yi-Hong, C. (2020). Feature Selection and
Classification using Random Forest Algorithm. Journal of AI and Data Science, 6(2), 89-
104.
Bhattacharya, D., Singh, P., & Jones, S. (2021). AI-Driven Agent-Based Models to Study
Vaccine Acceptance and COVID-19 Spread. Computational Epidemiology Review,
10(1), 67-85.
39
Azzari, C., Lodi, M., & Biolchini, A. (2020). Effectiveness of the 4CMenB Vaccine
Against Group B Meningococcal Disease in Italy. Vaccine Research Journal, 25(5), 341-
350.
Reynolds, D., Simmons, G., & Chen, T. (2023). Vaccine Schedule Recommendations for
Patients with Hematologic Malignancy Post-HCT or CAR T-Cell Therapy. Hematology
and Immunization Review, 16(1), 102-119.
40
Appendix:
import datetime
import os.path
import joblib
import pandas as pd
import pyperclip
import pyttsx3
import speech_recognition as sr
import tkinter as tk
import PIL
SCOPES = ["https://www.googleapis.com/auth/calendar"]
41
# Initialize text-to-speech engine
engine = pyttsx3.init()
def speak(text):
engine.say(text)
engine.runAndWait()
creds = None
if os.path.exists("token.json"):
creds.refresh(Request())
else:
creds = flow.run_local_server(port=0)
42
token.write(creds.to_json())
try:
event = {
'summary': summary,
'start': {
'dateTime': start_time,
'timeZone': 'UTC',
},
'end': {
'dateTime': end_time,
'timeZone': 'UTC',
},
return event.get('htmlLink')
return None
43
# Load the model and encoders
model = joblib.load('vaccine_predictor_model.pkl')
label_encoder = joblib.load('targetpop_label_encoder.pkl')
country_list = [
# List of vaccines
vaccine_list = [
44
'MR (Measles and rubella) vaccine',
'Measles vaccine'
def voice_command():
recognizer = sr.Recognizer()
audio = recognizer.listen(source)
try:
command = recognizer.recognize_google(audio)
process_command(command)
except sr.UnknownValueError:
except sr.RequestError:
def process_command(command):
45
global country_var, vaccine_var
if 'country' in command:
if country.lower() in command.lower():
country_var.set(country)
break
if vaccine.lower() in command.lower():
vaccine_var.set(vaccine)
break
try:
age_entry.delete(0, tk.END)
age_entry.insert(0, str(age))
46
elif 'schedule' in command:
schedule_vaccination()
def predict_and_schedule():
country = country_var.get()
vaccine = vaccine_var.get()
try:
# Get the input age in years from the user and convert it to months
age_in_years = int(age_entry.get())
except ValueError:
return
input_data.update(pd.DataFrame([input_dict]))
prediction = model.predict(input_data)
47
targetpop_pred = prediction[0][0]
ageadmin_pred = prediction[0][1]
schedulerounds_pred = prediction[0][2]
targetpop_pred_label = label_encoder.inverse_transform([int(targetpop_pred)])[0]
else:
schedulerounds_pred = round(schedulerounds_pred)
# Convert the predicted age administered (in months) back to years and months
result_text = (
"your ward is above the age for getting this vaccination, it is expected that this
vaccination has been administered\n"
48
speak("your ward is above the age for getting this vaccination, it is expected that
this vaccination is already administered.")
result_label.configure(text=result_text)
# Check if the user's age in months is less than the predicted age for vaccination
schedule_vaccination()
def months_to_years(months):
years = months // 12
remaining_months = months % 12
return total_months
49
def copy_to_clipboard(event_link):
if event_link:
pyperclip.copy(event_link)
def schedule_vaccination():
hours=1)).isoformat()
if event_link:
speak("Vaccination has been scheduled for next Monday. You can view it on your
calendar.")
50
# Create a 'Copy Link' button
copy_button.pack()
else:
root = tk.Tk()
root.geometry("600x400")
bg_image = Image.open("background.jpg")
51
# bg_image = bg_image.resize((600, 400), Image.Resampling.LANCZOS) # Resize
image to fit the window size
result_label.pack()
country_menu.pack(padx=10, pady=5)
vaccine_menu.pack(padx=10, pady=5)
52
ctk.CTkLabel(root, text="Age (in years):").pack(padx=10, pady=5)
age_entry = ctk.CTkEntry(root)
age_entry.pack(padx=10, pady=5)
predict_button.pack(padx=10, pady=10)
voice_button.pack(padx=10, pady=10)
result_label.pack(padx=10, pady=10)
root.mainloop()
53
54