Using Machine Learning to Predict Postprandial Blood Glucose in Type 1 Diabetics
CSEF · 2017 Computational Systems & Analysis
Overview
Objectives/Goals People with Type 1 Diabetes (T1D) must compute an insulin bolus dose for every meal to cover the carbohydrates and return the blood glucose (BG) level to euglycemia (normal level). The goal of this project is to create an algorithm to accurately predict BG levels two hours after a meal, which will enable people with T1D to compute insulin doses more accurately. Typically, bolus doses are computed using a carb to insulin ratio (i.e., "carb counting") and the current BG level. This approach is inaccurate because it ignores many factors such as prior BG dysregulation, exercise, food composition, stress, hormones, and sleep. This project will examine several of these factors. Methods/Materials The following data was collected over a 30 day period: insulin infusion data from a Tandem t:slim pump, BG data from a Dexcom G5 continuous glucose monitor, heartrate data from an Apple Watch, and nutritional information from the MyFitnessPal app. Data was extracted from these sources and used to create variables to predict BG levels. The Weka machine learning toolkit was used to train models using these variables and to determine which of the variables have the most effect on blood glucose. Results Variables were created to characterize BG dysregulation, heartrate (exercise), and meal composition. These variables were used to train a machine learning algorithm to predict 2-hr postprandial BG levels. This approach is much more accurate than the standard method, carb counting, at predicting 2-hr postprandial BG levels. Carb counting achieved a correlation of R = 0.35, while the new approach achieved R = 0.74. Conclusions/Discussion I was able to build a model that accurately predicts 2-hr postprandial BG levels. This model will enable patients to optimize bolus doses to achieve their target postprandial BG level. The project has resulted in several findings. First, machine learning can be used to improve insulin dosing. Second, the project demonstrated that heartrate, prior BG levels, and food composition are all important for computing accurate insulin bolus doses. Third, measuring BG levels 1-hr postprandial can enable more accurate glycemic control. This work is a step toward creating a completely closed-loop insulin delivery system. However, more immediately, the project has resulted in a method (1-hr postprandial BG measurement) that can enable people with T1D to more accurately control their BG levels.
Summary statement
Using machine learning techniques with data about heartrate (exercise), blood glucose dysregulation, and meal composition enables accurate prediction of two-hour postprandial blood glucose levels in Type 1 Diabetics.
Help received
I came up with this project topic on my own. I also collected the data and constructed the machine learning models by myself. My father helped me in extracting raw data from the various devices and converting it to a useable format. He also assisted me by critiquing my writing and poster.
Competition history
- CSEF 2017
Resources
Related projects
ISEF · 2017
Using Machine Learning to Predict Postprandial Blood Glucose in Type 1 Diabetics
CSEF · 2018
Type 2 Diabetes Prediction Using Longitudinal Machine Learning Analyses and Integrative Personal Omics Profiling
JSHS · 2023
GlucoseAssist: A Novel, Personalized System for Prediction of Blood Glucose Levels and Early Identification of Dysglycemic Events using Artificial Intelligence
ISEF · 2023
Optimizing Glycemic Control in Type 1 Diabetic Patients Using a Deep Learning-Based Artificial Pancreas With a Secure Glucagon and Insulin Delivery System
ISEF · 2025
Decoding Diabetes: Harnessing AI to Accurately Predict Real-Time and Future Blood Glucose Levels for Diabetes Management Using Diet, Exercise, Insulin Intake, and Heart Rate Variability
JSHS · 2025
Decoding Diabetes: Harnessing AI to Accurately Predict Real-Time and Future Blood Glucose Levels for Diabetes Management Using Diet, Exercise, Insulin Intake, and Heart Rate Variability
CWSF · 2026
In Silico Diabetes Management and Prediction: A Personalized Hybrid Physics-ML System
CSEF · 2016
Developing a Model of an Artificial Pancreas
Closest projects by meaning, across every fair and year in the corpus.
Browse more like this
Source: California Science & Engineering Fair public projects