AUTHOR=Duan Yuxin , Sui Weifan , Cai Zefeng , Xia YimaoXua , Li Jianyun , Fu Jianhua TITLE=Machine learning–based risk stratification for gastrointestinal bleeding in ICU patients with cirrhosis: evidence from the MIMIC database JOURNAL=Frontiers in Medicine VOLUME=Volume 12 - 2025 YEAR=2025 URL=https://www.frontiersin.org/journals/medicine/articles/10.3389/fmed.2025.1701973 DOI=10.3389/fmed.2025.1701973 ISSN=2296-858X ABSTRACT=BackgroundIn critically ill patients with cirrhosis, gastrointestinal bleeding (GIB) is a common complication that significantly impacts clinical outcomes during ICU hospitalization. Early identification of high-risk patients is crucial for preventing complications and guiding appropriate clinical interventions, which can improve treatment outcomes.ObjectiveTo develop and externally validate a machine learning model for predicting in-hospital GIB in ICU patients with cirrhosis, identify key predictors, and assess its clinical utility for risk stratification and decision-making.MethodsA retrospective cohort study was conducted, including 3,160 ICU patients diagnosed with cirrhosis from the Medical Information Mart for Intensive Care IV (MIMIC-IV) database. Patients were divided chronologically into training (n = 2,528) and testing (n = 632) cohorts based on their ICU admission dates. External validation was performed on a separate cohort of 523 ICU patients with cirrhosis extracted from the publicly available Electronic Intensive Care Unit (EICU) database. Key predictive variables were identified through a combination of the Boruta algorithm, correlation analysis, and variance inflation factor (VIF) assessment, ensuring both predictive relevance and control of multicollinearity. Six ML algorithms—logistic regression, k-nearest neighbors, support vector machine, random forest (RF), multilayer perceptron, extreme gradient boosting, and gradient boosting machine—were trained and evaluated through 10-fold cross-validation. Model performance was rigorously assessed based on the area under the receiver operating characteristic curve (AUC-ROC), accuracy, sensitivity, specificity, F1-score, calibration curves, and decision curve analysis (DCA). Shapley additive explanations (SHAP) analysis was employed to interpret and rank variable importance. Additionally, multivariable logistic regression models were constructed to elucidate the relationship between anticoagulant therapy and the incidence of in-ICU GIB after comprehensive adjustment for relevant clinical factors.ResultsAmong the ML algorithms evaluated, the RF model achieved AUC of 0.86 (95% CI: 0.84–0.88) in the training cohort and 0.72 (95% CI: 0.68–0.76) in the test cohort, with sensitivity 0.68, specificity 0.71, and precision 0.47. The key predictors identified by the model included red blood cell count, hemoglobin level, platelet count, and anticoagulant therapy, all of which were significantly associated with the risk of gastrointestinal bleeding. Decision curve analysis indicated that the RF model provides meaningful clinical utility for early risk stratification. Multivariable logistic regression further revealed that anticoagulant use independently correlated with a lower risk of in-ICU GIB (or: 0.29; 95% confidence interval: 0.24–0.34). Stratified analyses based on gender, age, weight, and additional subgroups consistently confirmed the robustness of the protective association between anticoagulant therapy and reduced GIB risk.ConclusionThe RF model demonstrated stable discrimination for predicting GIB risk in ICU patients with cirrhosis across multiple cohorts. Built on readily available clinical data, it enables timely risk stratification and informs individualized preventive interventions in critical care settings.