Machine learning–based prediction model for hypoglycemia during hospitalization in T2DM patients
Abstract Objective: This study aimed to develop a machine learning–based prediction model for hypoglycemia in hospitalized patients with type 2 diabetes mellitus (T2DM) by utilizing electronic medical records. The goal was to establish a reliable foundation for creating a web-based calculator or applet for clinical use. Methods: Predictive variables were identified through a comprehensive, evidence-based literature review. Potential hypoglycemia risk factors were extracted from electronic medical records using SQL queries generated by PLSQL software. The data set comprised hypoglycemic events occurring between June 2017 and January 2022 at the First Affiliated Hospital of Henan University of Science and Technology. After data preprocessing, binary logistic regression was applied to variables with a P value below 0.1. A hypoglycemia risk model was built using support vector machine (SVM) and random forest (RF) algorithms in MATLAB. The performance of these models was evaluated based on precision, recall, and accuracy, and compared to a binary logistic regression model. Hypoglycemia risk factors were ranked, and external validation was conducted to assess the model’s robustness. Results: Internal validation showed comparable performance between RF and SVM models. The RF model achieved a precision of 93.08%, accuracy of 77.05%, and recall of 77.52%, while the SVM model had 91.81% precision, 74.47% accuracy, and 75.00% recall. Both models outperformed binary logistic regression. External validation showed that the RF model had the highest rates of accuracy (91.50%) and recall (75.00%). The most significant predictors of hypoglycemia included the coefficient of variation, average daily blood glucose, and minimum average blood glucose level (BGmin). Conclusions: RF outperformed traditional logistic regression in predicting hypoglycemia in hospitalized T2DM patients. This model provides a solid basis for the development of websites and applets for the prediction of hypoglycemic events during hospitalization in real-world T2DM patients.
Authors
- Na Qi (ORCID: https://orcid.org/0000-0001-5333-1602)
- W. D. Niu (ORCID: https://orcid.org/0000-0003-0630-178X)
- Jiarong Huang (ORCID: https://orcid.org/0009-0007-7507-4601)
- Huiping Yuan (ORCID: https://orcid.org/0000-0002-4018-7127)
- Huifang Peng (ORCID: https://orcid.org/0000-0003-2738-2080)
- Hongwei� Jiang (ORCID: https://orcid.org/0000-0003-3807-7989)
- Shaowei Wang (ORCID: https://orcid.org/0000-0002-5536-6515)
- Xiaomin Zhang (ORCID: https://orcid.org/0000-0002-5678-7637)
- Chang Liu (ORCID: https://orcid.org/0000-0003-0324-8151)
- Ruirui Zhang (ORCID: https://orcid.org/0000-0001-8928-4238)
- Huimin Jia
- Hongyan Du (ORCID: https://orcid.org/0000-0002-4392-0849)
- YU Jing-li
- Xiaoli Liang (ORCID: https://orcid.org/0000-0002-9191-0063)
- Shuxin Li (ORCID: https://orcid.org/0000-0002-2971-4811)
- Zhumin Jia
Institutions
- Xidian University (CN)
- Henan University of Science and Technology (CN)
- Xi’an University (CN)
- First Affiliated Hospital of Henan University of Science and Technology (CN)
- Weifang Maternity and Child Care Hospital (CN)
Publication Details
- Journal
- Interdisciplinary Nursing Research
- Published
- 2025-03-01
- DOI
- https://doi.org/10.1097/nr9.0000000000000087
- Primary Topic
- Diabetes Management and Research
- Type
- article
- Field-Weighted Citation Impact
- 0.00