Using Artificial Intelligence to Develop a Multivariate Model with a Machine Learning Model to Predict Complications in Mexican Diabetic Patients without Arterial Hypertension (National Nested Case-Control Study): Metformin and Elevated Normal Blood Pressure Are Risk Factors, and Obesity Is Protective

J Diabetes Res. 2023 Feb 16:2023:8898958. doi: 10.1155/2023/8898958. eCollection 2023.


Diabetes mellitus is a disease with no cure that can cause complications and even death. Moreover, over time, it will lead to chronic complications. Predictive models have been used to identify people with a tendency to develop diabetes mellitus. At the same time, there is limited information regarding the chronic complications of patients with diabetes. Our study is aimed at creating a machine-learning model that will be able to identify the risk factors of a diabetic patient developing chronic complications such as amputations, myocardial infarction, stroke, nephropathy, and retinopathy. The design is a national nested case-control study with 63,776 patients and 215 predictors with four years of data. Using an XGBoost model, the prediction of chronic complications has an AUC of 84%, and the model has identified the risk factors for chronic complications in patients with diabetes. According to the analysis, the most crucial risk factors based on SHAP values (Shapley additive explanations) are continued management, metformin treatment, age between 68 and 104 years, nutrition consultation, and treatment adherence. But we highlight two exciting findings. The first is a reaffirmation that high blood pressure figures across patients with diabetes without hypertension become a significant risk factor at diastolic > 70 mmHg (OR: 1.095, 95% CI: 1.078-1.113) or systolic > 120 mmHg (OR: 1.147, 95% CI: 1.124-1.171). Furthermore, people with diabetes with a BMI > 32 (overall obesity) (OR: 0.816, 95% CI: 0.8-0.833) have a statistically significant protective factor, which the paradox of obesity may explain. In conclusion, the results we have obtained show that artificial intelligence is a powerful and feasible tool to use for this type of study. However, we suggest that more studies be conducted to verify and elaborate upon our findings.

MeSH terms

  • Aged
  • Aged, 80 and over
  • Artificial Intelligence
  • Blood Pressure
  • Case-Control Studies
  • Diabetes Mellitus*
  • Humans
  • Hypertension* / complications
  • Hypertension* / drug therapy
  • Hypertension* / epidemiology
  • Machine Learning
  • Metformin* / therapeutic use
  • Obesity / complications
  • Risk Factors


  • Metformin