Skip to main content
BMC Medical Informatics and Decision Making logoLink to BMC Medical Informatics and Decision Making
. 2025 Sep 26;25:341. doi: 10.1186/s12911-025-03189-z

Developing an interpretable machine learning model for easily detecting insulin resistance among breast cancer survivors: a cross-sectional study

Mengxia Fu 1,✉,#, Zhiming Peng 2,#, Xue Yu 3,#, Dapeng Lv 1, Min Wu 1,
PMCID: PMC12465519  PMID: 41013410

Abstract

Objective

To develop and validate a classification model for insulin resistance in female individuals who have survived breast cancer using easily obtainable clinical and demographic features.

Methods

Data were obtained from the U.S. National Health and Nutrition Examination Survey (NHANES) spanning 1999 to March 2020. A total of 340 female individuals who have survived breast cancer were included, and participants were randomly assigned to a training set (n = 239) and a testing set (n = 101). Multiple machine learning algorithms were trained, including Logistic Regression, Random Forest, and Support Vector Machine. Model performance was evaluated using area under the receiver operating characteristic curve (AUC) and decision curve analysis (DCA).

Results

All models demonstrated strong classification performance in the testing set, with AUC values exceeding 0.87. Among them, the Random Forest and Support Vector Machine models showed superior performance in DCA. Of the seven input features—body mass index, fasting blood glucose, triglyceride, HDL cholesterol, poverty income ratio, race, and education—fasting blood glucose had the highest positive feature importance for classifying insulin resistance.

Conclusions

This study demonstrates the feasibility of using machine learning algorithms to accurately predict insulin resistance in individuals who have survived breast cancer with a limited set of clinical and demographic variables. The Random Forest and Support Vector Machine models, in particular, offer strong classification performance and may support clinicians in early identification and management of insulin resistance among individuals in this high-risk population.

Supplementary Information

The online version contains supplementary material available at 10.1186/s12911-025-03189-z.

Introduction

The global estimate for new cases of breast cancer in 2022 was 2.30 million, accounting for 11.5% of all new cancer cases. In the same year, there were 0.67 million deaths due to breast cancer [1]. Due to improvements in screening techniques, the detection rate of breast cancer has increased, the mortality rate of breast cancer has decreased [2]. Most cases of breast cancer can be cured through multimodality treatment, although cure rates vary depending on subtype and clinical stage, hence the 5-year survival for breast cancer increased from 79% in 1990 to 93% in 2019 [3, 4]. The increasing incidence of breast cancer, coupled with higher rates of early detection and advancements in cancer therapies, has led to a growing population of individuals who have survived breast cancer and are at a higher risk for other comorbidities, particularly diabetes [5]. Diabetes affects up to one-third of patients with breast cancer [5]. Patients with both diabetes and breast cancer may experience worsened outcomes due to less intensive care for either condition [6].

Insulin resistance is a condition characterized by a diminished response to insulin in the cells of skeletal muscle, liver, and adipose tissue. It occurs when a certain concentration of insulin fails to elicit an adequate glucose response. Various factors contribute to the development of insulin resistance, including individuals with obesity including individuals with obesity, stress, medications (such as steroids), individuals who are pregnant, insulin antibodies, and genetic defects in insulin-signaling pathways [7]. Insulin resistance serves as a key indicator for the early diagnosis of diabetes mellitus. Numerous clinical studies have indicated that early intervention for diabetes mellitus yields better outcomes [811]. Therefore, identifying insulin resistance, which represents the earliest sign of diabetes mellitus, holds crucial importance within the clinical spectrum of individuals who have survived breast cancer.

Leveraging machine learning for classifying insulin resistance offers several advantages. It allows for the analysis of complex and multidimensional datasets, facilitating the automatic identification and learning from patterns within this data. Furthermore, machine learning models adapt to new data and refine classification over time, ultimately enhancing their accuracy and practicality in clinical practice.

In this study, we applied machine learning for individuals who have survived breast cancer to develop a model for classifying insulin resistance. First, we tried to develop a diagnostic algorithm using a number of easily obtained patient characteristics to expand the utilization of insulin resistance. Second, with this machine learning diagnostic model, we explained the features importance by using SHapley Additive exPlanations (SHAP) [12]. In this study, we utilized datasets from the National Health and Nutrition Examination Survey (NHANES) (1999-Mar, 2020) to explore the relationships between patient feature and insulin resistance. We identified 4 machine learning models capable of detecting insulin resistance based on 7 easily accessible features and subsequently compared the performance characteristics of these models. Additionally, our research integrated an advanced machine learning technique, specifically based on SHAP, to ascertain the contribution of each feature to insulin resistance identification. This approach enhances the potential for early intervention by providing insights into the individual impact of patient features on insulin resistance risk.

Methods

Study design

Our study utilized data from eleven consecutive NHANES cycles spanning from 1999 to Mar, 2020. NHANES is a cross-sectional study overseen by the Centers for Disease Control and Prevention (CDC), conducted biennially. It entails a thorough health and nutritional survey, physical examinations, and laboratory analyses conducted on a sample of U.S. residents, designed to be nationally representative. NHANES is conducted in biennial cycles, and some participants may appear in more than one cycle. To avoid bias from repeated measures, we identified participants using the unique identifier (SEQN) and retained only the first observation for each individual across the entire study period. This approach ensured that all observations were independent. For variables such as HOMA-IR, if multiple measurements were available for a participant across cycles, only the value from the first participation year was used in the analysis. Detailed information regarding NHANES methodology has been previously published on the CDC website, and the entirety of NHANES data is accessible for analysis. (http://www.cdc.gov/nchs/nhanes.htm). The National Center for Health Statistics Research Ethics Review Board approved the NHANES protocol, and each participant provided written consent. All records were anonymized before being accessed by the authors. All methods were performed in accordance with the approved guidelines and regulations.

Participant selection and inclusion/exclusion criteria

We initially included 107,622 participants from eleven consecutive NHANES cycles spanning 1999 to March 2020. Participants were excluded if they met any of the following criteria: age under 18 years, male sex, no history of breast cancer, or incomplete laboratory data necessary for the analysis. After these exclusions, 340 participants who had survived breast cancer and had complete data remained for the final analysis. A detailed flow diagram depicting the selection process and exclusions is presented in Fig. 1.

Fig. 1.

Fig. 1

The CONSORT flow diagram of data preprocessing from the NHANES (1999-Mar, 2020) database

Baseline characteristics encompassed age (years), gender, body mass index, total cholesterol levels (mg/dL), high-density lipoprotein (HDL) levels (mg/dL), triglyceride levels (mg/dL), fasting blood glucose levels (mg/dL), and glycohemoglobin levels (%). Hypertension was defined as a self-reported diagnosis of hypertension, receiving treatment for hypertension or a mean systolic blood pressure ≥ 130 mmHg or mean diastolic blood pressure ≥ 80 mmHg as per the 2017 ACC/AHA Hypertension Guideline [13]. Diabetes mellitus was defined as a self-reported diagnosis of diabetes mellitus, or receiving treatment for diabetes mellitus, or a fasting blood glucose level ≥ 126 mg/dL, random blood glucose level ≥ 200 mg/dL, or hemoglobin A1c level ≥ 6.5% [14]. Participants who had experienced angina pectoris, coronary heart disease, myocardial infarction, congestive heart failure, or cerebrovascular disease were considered individuals with a history of cardiovascular disease. Participants who had experienced breast cancer were considered individuals who had survived breast cancer. We divided the population according to the frequency of smoking. The smoking behavior of participants was divided into: never (smoked less than 100 cigarettes in life), former (smoked more than 100 cigarettes in life and smoke not at all now), now (smoked more than 100 cigarettes in life and smoke some days or every day). To optimize the utilization of insulin resistance, we identified a subset of common features for machine learning, known to be associated with insulin resistance. The aim was to develop a classification algorithm that is both user-friendly and capable of achieving robust performance in discriminating insulin resistance status, which classification holds significant potential in clinical settings.

Definition of insulin resistance

Insulin resistance was assessed using the Homeostasis Model Assessment of insulin resistance (HOMA-IR), which is considered the most acceptable method for estimating insulin resistance. The calculation of HOMA-IR involves fasting plasma insulin and fasting plasma glucose measurements, obtained at the same examination time point as the other predictors in this study. Insulin resistance, defined as increased HOMA-IR, is strongly associated with the development of type 2 diabetes mellitus. This association remains statistically independent of impaired glucose tolerance status, obesity, and body fat distribution. Elevated values of HOMA-IR are independently linked to a higher risk of developing prediabetes. The formula used by HOMA-IR to quantify insulin resistance is fasting plasma insulin (µU/ml) multiplied by fasting plasma glucose (mg/dL) divided by 405.23 [15]. For adults, a HOMA-IR value of 2.5 is the cutoff indicating insulin resistance [16]. In this study, HOMA-IR values were computed for participants from the NHANES databases. Participants were then categorized into without insulin resistance and with insulin resistance groups based on their HOMA-IR values (≤ or > 2.5).

Pre-processing and extraction of machine learning features

We divided the patient population randomly, allocating 70% to the training set for model development, and the remaining 30% to the testing set. Theclassification features for insulin resistance (HOMA-IR > 2.5) included readily accessible patient features including age, race, education, poverty income ratio, body mass index, glycohemoglobin, fasting blood glucose, HDL cholesterol, total cholesterol, triglyceride, hypertension, cardiovascular disease, smoke, and alcohol. All features were measured concurrently with the outcome (HOMA-IR) in the same examination cycle, reflecting a cross-sectional design. All continuous features were standardized before model training. Features with loss rates under 10% were selected. To prevent potential data leakage, imputation of missing values was conducted after the train-test split, and separately within each dataset. Missing values of continuous variables were filled with their median, while categorical variables were filled with their nearest filled method. Initially, all features were standardized (mean = 0, standard deviation = 1) prior to applying the least absolute shrinkage and selection operator (LASSO) regression model to ensure comparability across variables of different scales. Variables considered “irrelevant” were those whose coefficients were shrunk to zero under the optimal penalty parameter (λ) selected via 10-fold cross-validation performed only within the training set, indicating minimal contribution to the prediction of insulin resistance. Following this pre-processing and feature extraction, irrelevant variables were eliminated from the model to mitigate the risk of overfitting. Then, traditional machine learning algorithms such as random forest [17], eXtreme Gradient Boosting (XGBoost) [18], logistic regression and Support Vector Machine [19] were utilized.

Model building process

In our study, we employed a range of traditional machine learning algorithms, including random forest, XGBoost, logistic regression, and Support Vector Machine (SVM). Each algorithm underwent parameter tuning using 10-fold cross-validation applied exclusively within the training set for hyperparameter tuning and feature selection to optimize performance. Following this, the final model was retrained on the entire training set and evaluated on the independent test set to ensure unbiased assessment. To further assess model robustness, we additionally performed bootstrap resampling (1,000 iterations) on the training set and summarized the variability in performance metrics. For performance evaluation, we utilized ROC curves (receiver operating characteristic) and calculated the corresponding AUC (area under the curve) for each algorithm. ROC curves are effective in illustrating the trade-offs between sensitivity and specificity across different threshold settings. An AUC value greater than 0.80 was targeted, indicating strong discriminatory ability and suitability for classifying insulin resistance. Additionally, 95% confidence intervals (CIs) were calculated for key performance metrics including AUC, sensitivity, specificity, precision, and F1-score, using bootstrap resampling with 1,000 iterations to reflect statistical uncertainty and provide measures of precision. We also employed SHAP values to explore feature importance and provide insights into how each machine learning model made classification. SHAP values help in understanding the contribution of each feature to the model’s output and provide explanations for individual classification.

Statistical analysis

The NHANES is a multiple and complex survey involving weighted data calculations to ensure representative sample estimates, as outlined in analytical guidelines such as “US NHANES: Analytical Guidelines, 2011–2014 and 2015–2016,” which are accessible online. These weighted data are typically used to estimate nationwide occurrence or prevalence rates. However, our study’s objective did not focus on estimating nationwide prevalence rates. Instead, our goal was to explore the relationship between insulin resistance and various features for the purpose of training our machine learning model. As such, we chose to utilize the original unweighted data from the NHANES databases for our model training. In the context of unweighted data, continuous variables were reported as median with interquartile range, and categorical data as number and percentage. We assessed differences in variables related to insulin resistance using appropriate statistical tests: Chi-square tests or Fisher’s exact probability for categorical variables, and the Wilcoxon rank-sum test for continuous variables. All reported p-values were two-sided and considered significant at p < 0.05. To assess potential collinearity among numeric predictors, we calculated pairwise Pearson correlation coefficients and visualized them in a correlation heatmap. For our analyses and machine learning implementations, we utilized R (version 4.3.3), conducting both algorithmic modeling and statistical assessments within this environment. Key R packages used for model building included randomForest (4.7.1.2), xgboost (1.7.8.1), e1071 (1.7.16) for SVM, glm (4.1.8) for logistic regression, and kernelshap (0.7.0) for SHAP value calculation. Hyperparameters for each model were tuned via 10-fold cross-validation. The final hyperparameters were as follows: random forest with 500 trees; XGBoost with learning rate 0.1, max depth 6, and 100 rounds; SVM using radial kernel; logistic regression with default settings. Bootstrap methods can be used to estimate 95% CIs for metrics like AUC, sensitivity, and specificity. This approach enabled us to effectively explore and understand the associations between insulin resistance and various demographic and clinical factors among individuals within the NHANES dataset.

Results

Participant selections from the NHANES databases

We initially included 107,622 participants from the NHANES (1999–Mar, 2020). After exclusion, there were 340 participants in the final analysis. Excluded participants were as follows: 44,581 due to age < 18 years; 30,427 due to male; 31,734 due to non-breast cancer history; 540 due to incomplete laboratory data (Fig. 1). Of all participants, we randomly selected 239 participants to serve as the training group, and 101 participants who served as the testing group. In the training group, we trained the model with the following algorithms: XGBoost, Random Forest, Logistic Regression and Support Vector Machine. Their AUCs were finally compared.

Baseline characteristics of participants

The demographic characteristics of the study participants, both with and without insulin resistance, from 1999 to Mar, 2020 (US NHANES), are summarized in Table 1. A total of 340 participants were included in the final analysis, among whom 210 (62%) were non-Hispanic white, with a median age of 69 years (interquartile range, 60–79). Among these participants, 184 were participants who had insulin resistance. Those participants who had insulin resistance were more likely to be obese, non-Hispanic white, never drink alcohol, had a lower average family income, and had diabetes and hypertension. Additionally, levels of glycohemoglobin, fasting blood glucose, plasma insulin, and triglycerides were higher in participants who had insulin resistance (all p < 0.05).

Table 1.

Baseline data according to insulin resistance or not

Variable All Participants,
N = 340
Without Insulin Resistance,
N = 156
With Insulin Resistance,
N = 184
p-value
HOMA_IR 2.9 (1.7, 4.6) 1.5 (0.9, 1.9) 4.8 (3.4, 7.1) < 0.001
Age 69 (60, 79) 71 (60, 80) 68 (60, 77) 0.423
Race 0.004
 Mexican American 33 (9.7%) 6 (3.8%) 27 (15%)
 Other Hispanic 23 (6.8%) 8 (5.1%) 15 (8.2%)
 Non-Hispanic White 210 (62%) 108 (69%) 102 (55%)
 Non-Hispanic Black 55 (16%) 23 (15%) 32 (17%)
 Other 19 (5.6%) 11 (7.1%) 8 (4.3%)
Education 0.002
 Less than 9th grade 31 (9.1%) 8 (5.1%) 23 (13%)
 9-11th grade 44 (13%) 16 (10%) 28 (15%)
 High school graduate 77 (23%) 31 (20%) 46 (25%)
 Some college or AA degree 98 (29%) 45 (29%) 53 (29%)
 College graduate or above 90 (26%) 56 (36%) 34 (18%)
Poverty_income_ratio 2.29 (1.24, 4.36) 3.17 (1.41, 4.99) 1.93 (1.13, 3.73) 0.001
Body_mass_index 28 (24, 33) 25 (23, 29) 31 (27, 37) < 0.001
Glycohemoglobin 5.70 (5.40, 6.05) 5.50 (5.30, 5.80) 5.90 (5.60, 6.40) < 0.001
Fasting_blood_glucose 103 (94, 119) 97 (90, 103) 112 (102, 130) < 0.001
Plasma_insulin 11 (7, 18) 65(4, 8) 17 (12, 25) < 0.001
HDL_Cholesterol 59 (47, 69) 64 (54, 76) 54 (44, 64) < 0.001
Total_cholesterol 5.07 (4.46, 5.86) 5.14 (4.60, 5.94) 5.02 (4.37, 5.81) 0.144
Triglyceride 113 (85, 157) 96 (73, 134) 133 (94, 178) < 0.001
Diabetes 108 (32%) 20 (13%) 88 (48%) < 0.001
Hypertension 251 (74%) 103 (66%) 148 (80%) 0.004
Cardiovascular_disease 55 (16%) 21 (13%) 34 (18%) 0.270
Smoke 0.962
 Never 207 (61%) 96 (62%) 111 (60%)
 Former 105 (31%) 47 (30%) 58 (32%)
 Current 28 (8.2%) 13 (8.3%) 15 (8.2%)
Alcohol 0.024
 Never 80 (24%) 28 (18%) 52 (28%)
 Former 83 (24%) 35 (22%) 48 (26%)
 Current 177 (52%) 93 (60%) 84 (46%)

Variable selection by LASSO regression

We utilized the least absolute shrinkage and selection operator (LASSO) regression model to identify the most relevant variables associated with insulin resistance, aiming to reduce data dimensionality and optimize the classification performance of the machine learning model. The relationships between the variation in cross-validation error and the log-transformed penalty parameter (λ) in LASSO regression are illustrated in Fig. S1A. Additionally, Fig. S1B and S1C highlights 7 features, including body mass index [20], fasting blood glucose [21], HDL cholesterol [22], triglyceride [22], poverty income ratio [23], race [24] and education [25], with nonzero coefficients in the best-fit LASSO regression model, indicating their relevance to insulin resistance. The selection of these variables was informed by their well-established clinical relevance and support from prior literature linking them to insulin resistance and metabolic health [2026]. Subsequently, variance inflation factors (VIFs) were employed to evaluate multicollinearity among the features included in the final model, with VIF values greater than 10 considered indicative of multicollinearity. Evaluation of multicollinearity between all identified features using VIF suggested the absence of multicollinearity (Fig. S1D). Fig. S1E also displayed the correlation heatmap among numeric predictors. No pairwise correlation exceeded |0.80|, suggesting that collinearity was not a major concern. Subsequently, 4 machine learning models were employed on the US NHANES datasets, utilizing the 7-variable training datasets for model training.

Classification values from 4 machine learning models

A tenfold cross-validation was applied for the training and validation sets to prevent overfitting, and it was also used to formulate classification models. In our cases, the model with the highest area under curve (AUC) of the receiver operating characteristic (ROC) was selected as the optimal model of each algorithm. The performance metrics for each model are summarized in Table S1. Among all machine learning models, the Support Vector Machine model demonstrated the highest performance, achieving an accuracy of 0.851 (95% CI: 0.767–0.913) on the testing set. The ROC curves and or precision-recall (PR) curves for all four models are depicted in Fig. 2. Both the ROC and PR curves consistently exhibited AUC values exceeding 0.87 in the testing sets. Specifically, in Fig. 2A, the AUC values of the ROC curves for the Random Forest, XGBoost, Logistic Regression, and Support Vector Machine models on the testing set were observed to be 0.885 (95% CI: 0.816–0.956), 0.873 (95% CI: 0.806–0.940), 0.885 (95% CI: 0.817–0.954) and 0.894 (95% CI: 0.831–0.958), respectively. We compared the discrimination performance of four machine learning models for predicting insulin resistance using DeLong’s test to assess differences in AUC. Although minor differences in AUC values were observed, none were statistically significant after Bonferroni and FDR correction (all adjusted p-values > 0.05, Table S2), indicating comparable predictive performance among these models. In Fig. 2B, the AUC values of the PR curves for the Random Forest, XGBoost, Logistic Regression, and Support Vector Machine models on the testing set were observed to be 0.919 (95% CI: 0.835–0.963), 0.899 (95% CI: 0.827–0.948), 0.880 (95% CI: 0.796–0.972), and 0.896 (95% CI: 0.831–0.956), respectively. The calibration curves showed that the XGBoost model performed worst among the 4 models (Fig. S2). According to the DCA curves [27] (Fig. 3), the Random Forest and Support Vector Machine models exhibited greater net benefit along with the threshold probability compared with other models, indicating that the Random Forest and Support Vector Machine models were the optimal models with favorable clinical utility. Consequently, the Random Forest and Support Vector Machine-based classification model was selected for further analysis.

Fig. 2.

Fig. 2

The ROC and PR curve of the 4 machine learning models. Machine learning model was utilized to fit the classification between insulin resistance and patient characteristics. The plots show the ROC (A) and PR (B) curves of XGBoost, Random Forest, Logistic Regression, and Support Vector Machine. ROC curve, receiver operating characteristic curve; PR curve, precision-recall curve. XGB, Extreme Gradient Boosting algorithm; RF, Random Forest algorithm; LR, Logistic Regression algorithm; SVM, Support Vector Machine algorithm

Fig. 3.

Fig. 3

Decision curves of machine learning models in classifying insulin resistance. The black line represents the net benefit of assuming that all patients develop insulin resistance. The blue line represents the net benefit of assuming that none develop insulin resistance. DCA curve, Decision curve analyses curve; XGB, Extreme Gradient Boosting algorithm; RF, Random Forest algorithm; LR, Logistic Regression algorithm; SVM, Support Vector Machine algorithm

Relative importance of parameters in the random forest and support vector machine algorithms

In our investigation using Random Forest and Support Vector Machine classification models, we assessed the relative importance of 7 features (Fig. 4A). Across both algorithms, all features displayed similar levels of importance. Notably, fasting blood glucose emerged as the most influential factor in classifying insulin resistance, with importance scores of 0.18 in Random Forest and 0.20 in Support Vector Machine, indicating its primary role compared to other variables. Following fasting blood glucose, the features influencing insulin resistance in descending order of importance were body mass index (0.17 in Random Forest and 0.19 in Support Vector Machine), HDL cholesterol, triglyceride (0.06 in both models), and poverty income ratio (0.06 in Random Forest and 0.01 in Support Vector Machine). The SHAP (SHapley Additive exPlanations) values in both Random Forest and Support Vector Machine models illustrated the relative contributions and directionality of these features towards insulin resistance (Fig. 4B). Both algorithms clearly delineated features into either positively or negatively associated with insulin resistance. Features such as fasting blood glucose, body mass index, triglyceride, and race1 (Mexican American) exhibited a positive impact on insulin resistance. In contrast, HDL cholesterol, poverty income ratio, and education5 (college graduate or above) demonstrated a negative impact on insulin resistance. These insights highlight the distinct roles and contributions of various demographic and clinical factors in classifying insulin resistance among individuals who have survived breast cancer.

Fig. 4.

Fig. 4

Impact explanation of features for classifying insulin resistance. Features importance and the explanation on the insulin resistance classified by the SHAP value in the Random Forest algorithm (A) and SVM (B). Race1 indicates Mexican American; Education5 indicates college graduate or above. SHAP, SHapley Additive exPlanations. SVM, Support Vector Machine algorithm

Incremental value of the full model over single predictors

To assess the incremental value of individual predictors in a transparent and interpretable manner, we used LR models for the single-variable analyses rather than more complex machine learning algorithms. This approach allows a direct comparison of AUCs between individual predictors and the full multivariable model without the influence of model-specific tuning or non-linear interactions, thereby focusing on interpretability rather than maximal predictive performance. Table 2 presents the discriminative ability (AUC and 95% CI) of each predictor alone compared with the full multivariable model. Among individual predictors, fasting blood glucose achieved the highest AUC (0.807, 95% CI: 0.761–0.853), followed by body mass index (0.773, 95% CI: 0.724–0.822). All other predictors demonstrated lower discriminative ability (AUC < 0.700). The full model yielded an AUC of 0.880 (95% CI: 0.796–0.972), which was significantly higher than that of any single predictor (all p < 0.001, DeLong test), demonstrating the added value of combining multiple predictors.

Table 2.

Incremental value of the full model over single predictors in discriminating insulin resistance (AUC and DeLong test)

Variable Single Variable AUC (95% CI) Full Model AUC (95% CI) Increment p-value
Fasting blood glucose 0.807 (0.761–0.853) 0.880 (0.796–0.972) + 0.073 < 0.001
Body mass index 0.773 (0.724–0.822) 0.880 (0.796–0.972) + 0.107 < 0.001
Triglyceride 0.690 (0.634–0.746) 0.880 (0.796–0.972) + 0.190 < 0.001
HDL Cholesterol 0.683 (0.627–0.740) 0.880 (0.796–0.972) + 0.197 < 0.001
Education 0.623 (0.566–0.681) 0.880 (0.796–0.972) + 0.257 < 0.001
Poverty income ratio 0.602 (0.542–0.663) 0.880 (0.796–0.972) + 0.278 < 0.001
Race 0.560 (0.507–0.612) 0.880 (0.796–0.972) + 0.320 < 0.001

AUC, area under the ROC curve; CI, confidence interval. Incremental value = difference in AUC between the full model and the individual predictor

Discussion

In this study, we leveraged machine learning techniques and data from the NHANES databases to construct a robust model for classifying insulin resistance in individuals who have survived breast cancer. Our model demonstrated strong diagnostic performance, achieving an AUC of 0.894 (95% CI: 0.831–0.958) using 7 easily accessible patient features. To our knowledge, this is the first study to apply multiple machine learning approaches specifically to predict insulin resistance among individuals who have survived breast cancer in the United States. The principles of machine learning involve developing algorithms to facilitate the creation of classification models for various outcomes. Artificial intelligence has the potential to revolutionize disease care by shifting from conventional treatment approaches to tailored, data-driven individualized care strategies. While machine learning models may exhibit strong classification accuracy in terms of discrimination and calibration, their usefulness in clinical practice can vary. A model with impressive performance metrics may still have limited applicability if the threshold probabilities of the net benefit are impractical. Therefore, we employed DCA curves to evaluate the clinical relevance and practical applicability of our machine learning models. Our findings indicate that insulin resistance can be predicted effectively using easily accessible information with the aid of machine learning techniques.

Identifying insulin resistance is critical within the spectrum of diabetes mellitus, yet calculating the HOMA-IR typically necessitates insulin levels, which are not routinely gathered in clinical practice. Therefore, the development of a classification model for insulin resistance that does not rely on empirical insulin values is essential. Despite limitations, several studies have explored the use of machine learning for classifying insulin resistance [2830]. For instance, a study on renal dysfunction achieved moderate classification power (best AUC of 0.81) using 29 features, while another recent study employed 18 complex parameters to develop algorithms with good performance [28, 30]. Another study on the Korean population achieved an AUC of 0.86 based on 9 features, slightly weaker than our model’s classification power (AUC of 0.894) [29]. Notably, our model has two significant strengths compared to existing ones: it exhibits better classification power (highest AUC) and is more generalizable (requiring only 7 easily obtainable features).

In both the Random Forest and Support Vector Machine models, body mass index and blood triglyceride levels were identified as significant features influencing insulin resistance (Fig. 4). These findings are consistent with prior research that has demonstrated associations between both body mass index and triglyceride levels with insulin resistance [26, 28, 31]. Insulin resistance can lead to increased production of low-density lipoprotein, which contributes to hypertriglyceridemia, potentially exacerbating the progression of breast cancer [32]. Moreover, a prospective study highlighted lower serum triglyceride levels in patients associated with reduced overall mortality risk compared to those with higher levels [33]. These results underscore the crucial role of serum triglyceride levels in the development of insulin resistance among individuals who have survived breast cancer, reinforcing our current findings.

Although there was a concern about potential data leakage related to body mass index (BMI), we assess its impact as likely minimal. Firstly, across both the Random Forest and Support Vector Machine models, our consistent observation was that fasting blood glucose emerged as the most influential variable in classifing insulin resistance among individuals who have survived breast cancer (see Fig. 4). Secondly, the HOMA-IR formula, integral to our analysis, incorporates plasma insulin and fasting blood glucose-not BMI. Thirdly, our dataset included patients with breast cancer and diabetes mellitus, where fasting blood glucose levels varied widely (from < 100 to 1000 mg/dL in cases of uncontrolled diabetes). Therefore, we believe any potential data leakage from BMI had a negligible effect on our study’s outcomes.

The developed machine learning models demonstrated strong predictive performance using clinically accessible variables, which supports their potential utility in clinical settings. To facilitate practical implementation, we propose that the final model could be integrated into an online risk calculator or a nomogram to assist clinicians in identifying patients at high risk of insulin resistance. A decision threshold based on maximizing Youden’s index or optimizing sensitivity and specificity balance can be established to guide clinical interventions, such as lifestyle modification or further diagnostic testing. Future work will focus on validating the model prospectively and developing user-friendly tools to support clinical decision-making.

Our study acknowledges several limitations. Firstly, we conducted single measurements of fasting blood glucose and blood insulin during the survey, potentially overlooking the chronic status of patients. Secondly, our participant selection was limited to those with measured fasting blood glucose and blood insulin, possibly introducing selection bias. Thirdly, by focusing on constructing a classification model for insulin resistance using demographic and clinical data, we did not incorporate NHANES survey weights, potentially resulting in sampling bias and restricting the generalizability of our findings. Fourthly, although we divided the NHANES data into training and testing sets, we did not validate our classification models using external data sources, which may restrict the generalizability of the developed machine learning models to other populations. To partially address this, future work could consider temporal validation using more recent NHANES cycles as a proxy for external validation. Nevertheless, we emphasize the necessity of validating the models on independent external cohorts from diverse populations to confirm their broader applicability. Such external validation will be crucial before clinical implementation to ensure robustness and reliability across different demographic and clinical settings. Lastly, our study lacked detailed information necessary to distinguish between different types of insulin resistance (e.g., primary vs. secondary insulin resistance). However, diagnosing the etiology of insulin resistance typically involves a multifaceted approach beyond our study’s scope, incorporating biochemical data, magnetic resonance imaging, and genetic screening.

Conclusions

This study represents a pioneering effort in utilizing machine learning techniques to classify insulin resistance among individuals who have survived breast cancer. Our research demonstrates the robustness and efficacy of Support Vector Machine and Random Forest algorithms as dependable models. These models have the potential to aid clinicians in customizing precise management strategies and initiating timely interventions for individuals who have survived breast cancer who face the risk of insulin resistance.

Supplementary Information

Below is the link to the electronic supplementary material.

Supplementary Material 1 (468.9KB, docx)

Acknowledgements

None.

Abbreviations

AUC

Areas under the curve

HOMA-IR

Homeostasis Model Assessment of insulin resistance

LASSO

Least absolute shrinkage and selection operator

NHANES

National Health and Nutrition Examination Survey

ROC

Receiver operating characteristic

SHAP

SHapley Additive exPlanation

XGBoost

eXtreme Gradient Boosting

Author contributions

M.F and M.W conceived and designed the study. M.F and Z.P analyzed the data and drafted the article. X.Y analyzed the data and revised the article. D.L provided technical support. M.W provided final approval of the version to be submitted.

Funding

The authors have no funding sources to declare.

Data availability

The data that support the findings of this study are available from NHANES database.

Declarations

Ethics approval and consent to participate

Not applicable.

Consent for publication

Not applicable.

Competing interests

The authors declare no competing interests.

Footnotes

The original version of this article was revised: “the article note, order of affiliations and affiliations details for Dapeng Lv and Min Wu have been corrected.”

Publisher’s note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Mengxia Fu, Zhiming Peng and Xue Yu contributed equally to the work and should be considered as co-first authors.

Change history

11/24/2025

A Correction to this paper has been published: 10.1186/s12911-025-03284-1

Contributor Information

Mengxia Fu, Email: fmx3973@bjsjth.cn.

Min Wu, Email: wumin3736@bjsjth.cn.

References

  • 1.Ferlay J, Lam EM. F, Global cancer observatory: Cancer Today. Lyon, France: International Agency for Research on Cancer. accessed [08 03 2024]. 2024. Available from: https://gco.iarc.who.int/today
  • 2.Caswell-Jin JL, et al. Analysis of breast cancer mortality in the US-1975 to 2019. JAMA. 2024;331(3):233–41. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 3.Smolarz B, Nowak AZ, Romanowicz H. Breast Cancer-epidemiology, classification, pathogenesis and treatment (Review of Literature). Cancers (Basel). 2022;14(10).
  • 4.Siegel RL, Giaquinto AN, Jemal A. Cancer statistics, 2024. CA Cancer J Clin. 2024;74(1):12–49. [DOI] [PubMed] [Google Scholar]
  • 5.Peairs KS, et al. Diabetes mellitus and breast cancer outcomes: a systematic review and Meta-Analysis. J Clin Oncol. 2010;29(1):40–6. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 6.Shahid RK et al. Diabetes and cancer: risk, challenges, management and outcomes. Cancers (Basel). 2021;13(22).
  • 7.Lee SH, Park SY, Choi CS. Insulin resistance: from mechanisms to therapeutic strategies. Diabetes Metab J. 2022;46(1):15–37. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 8.Cheung YM, et al. The effects of diabetes and glycemic control on cancer outcomes in individuals with metastatic breast cancer. J Clin Endocrinol Metab. 2022;107(9):2511–21. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 9.Lega IC, et al. The impact of diabetes on breast cancer treatments and outcomes: a population-based study. Diabetes Care. 2018;41(4):755–61. [DOI] [PubMed] [Google Scholar]
  • 10.Sonnenblick A, et al. Impact of diabetes, insulin, and Metformin use on the outcome of patients with human epidermal growth factor receptor 2-Positive primary breast cancer: analysis from the ALTTO phase III randomized trial. J Clin Oncol. 2017;35(13):1421–9. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 11.Tang GH, et al. Association of Metformin with breast cancer incidence and mortality in patients with type II diabetes: a GRADE-assessed systematic review and meta-analysis. Cancer Epidemiol Biomarkers Prev. 2018;27(6):627–35. [DOI] [PubMed] [Google Scholar]
  • 12.M;, L.S. and, I LS. A unified approach to interpreting model predictions. Adv Neural Inf Process Syst. 2017;30.
  • 13.Whelton P.K., et al. 2017 acc/aha/aapa/abc/acpm/ags/apha/ash/aspc/nma/pcna guideline for the prevention, detection, evaluation, and management of high blood pressure in adults: a report of the American college of cardiology/american heart association task force on clinical practice guidelines. Hypertension. 2018;71(6):e13–115. [DOI] [PubMed] [Google Scholar]
  • 14.Menke A, et al. Prevalence of and trends in diabetes among adults in the united states, 1988–2012. JAMA. 2015;314(10):1021–9. [DOI] [PubMed] [Google Scholar]
  • 15.Matthews DR, et al. Homeostasis model assessment: insulin resistance and beta-cell function from fasting plasma glucose and insulin concentrations in man. Diabetologia. 1985;28(7):412–9. [DOI] [PubMed] [Google Scholar]
  • 16.Muniyappa R, et al. Current approaches for assessing insulin sensitivity and resistance in vivo: advantages, limitations, and appropriate usage. Am J Physiol Endocrinol Metab. 2008;294(1):E15–26. [DOI] [PubMed] [Google Scholar]
  • 17.Breiman L, Forests R. Mach Learn. 2001;45(1):5–32. [Google Scholar]
  • 18.Chen TQ, Guestrin C. Xgboost: a scalable tree boosting system. Proceedings of the 22nd ACM SIGKDD International Conference on Knowledge Discovery and Data Mining. 2016:785–794.
  • 19.Boser BE, Guyon IM, Vapnik VN. A training algorithm for optimal margin classifiers, In: Proceedings of the fifth annual workshop on Computational learning theory. 1992, Association for Computing Machinery: Pittsburgh, Pennsylvania, USA. pp. 144–152.
  • 20.Sinaiko AR, et al. Relation of body mass index and insulin resistance to cardiovascular risk factors, inflammatory factors, and oxidative stress during adolescence. Circulation. 2005;111(15):1985–91. [DOI] [PubMed] [Google Scholar]
  • 21.Bonora E, et al. Homeostasis model assessment closely mirrors the glucose clamp technique in the assessment of insulin sensitivity: studies in subjects with various degrees of glucose tolerance and insulin sensitivity. Diabetes Care. 2000;23(1):57–63. [DOI] [PubMed] [Google Scholar]
  • 22.DeForest N, et al. Genome-wide discovery and integrative genomic characterization of insulin resistance loci using serum triglycerides to HDL-cholesterol ratio as a proxy. Nat Commun. 2024;15(1):8068. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 23.Barton AW, et al. Childhood poverty, immune cell aging, and African americans’ insulin resistance: a prospective study. Child Dev. 2022;93(5):1616–24. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 24.Danielson KK, et al. Racial and ethnic differences in an estimated measure of insulin resistance among individuals with type 1 diabetes. Diabetes Care. 2010;33(3):614–9. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 25.Xu Z, et al. Association between vitamin D3 levels and insulin resistance: a large sample cross-sectional study. Sci Rep. 2022;12(1):119. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 26.Tsai SF, et al. Development and validation of an insulin resistance model for a population without diabetes mellitus and its clinical implication: a prospective cohort study. EClinicalMedicine. 2023;58:101934. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 27.Van Calster B, et al. Reporting and interpreting decision curve analysis: a guide for investigators. Eur Urol. 2018;74(6):796–804. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 28.Lee CL, Liu WJ, Tsai SF. Development and validation of an insulin resistance model for a population with chronic kidney disease using a machine learning approach. Nutrients. 2022;14(14).
  • 29.Park S, Kim C, Wu X. Development and validation of an insulin resistance predicting model using a machine-learning approach in a population-based cohort in Korea. Diagnostics (Basel). 2022;12(1).
  • 30.Chakradar M, et al. A Non-invasive approach to identify insulin resistance with triglycerides and HDL-c ratio using machine learning. Neural Process Lett. 2023;55(1):93–113. [Google Scholar]
  • 31.Schrauben SJ, et al. Insulin resistance and chronic kidney disease progression, cardiovascular events, and death: findings from the chronic renal insufficiency cohort study. BMC Nephrol. 2019;20(1):60. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 32.Scully T, et al. SAT-137 the effect of hypertriglyceridemia on triple negative breast cancer progression. J Endocr Soc. 2020;4(Suppl 1):SAT–137. 10.1210/jendso/bvaa046.1408. [Google Scholar]
  • 33.Lofterød T, et al. Impact of pre-diagnostic triglycerides and HDL-cholesterol on breast cancer recurrence and survival by breast cancer subtypes. BMC Cancer. 2018;18(1):654. [DOI] [PMC free article] [PubMed] [Google Scholar]

Associated Data

This section collects any data citations, data availability statements, or supplementary materials included in this article.

Supplementary Materials

Supplementary Material 1 (468.9KB, docx)

Data Availability Statement

The data that support the findings of this study are available from NHANES database.


Articles from BMC Medical Informatics and Decision Making are provided here courtesy of BMC

RESOURCES