Library
PubMed
research article
Professional

Machine learning models to predict the recurrence of common bile duct stones after ERCP.

Source: PubMed, NCBI / U.S. National Library of Medicine

BMC gastroenterologyHan Xu, Ye Mujie, Tian Ye, et al.Published 6/11/2026Last synced 6/12/2026Status: syncedPMID: 42271287DOI: 10.1186/s12876-026-04990-4

To construct predictive models for the recurrence of common bile duct stones (CBDS) following endoscopic retrograde cholangiopancreatography (ERCP). This retrospective study analyzed data from 1,130 patients who were randomly divided into a training set (70%) and a test set (30%). Feature selection was performed using the boruta algorithm and multivariable logistic regression (LR), followed by addressing data imbalance through the Synthetic Minority Over-sampling Technique (SMOTE). Predictive models were developed utilizing random forest (RF), extreme gradient boosting (XGBoost), and LR. We optimized these models through random search and ten-fold cross-validation to identify the best parameters. After model development, we compared their area under the curve (AUC), accuracy, recall, precision, F1-score, and decision curve analysis (DCA) to select the most optimal model. Ultimately, the optimal model was interpreted using shapley additive explanations (SHAP). Eight risk factors were identified and used to construct the predictive model, including clinical course, stone diameter, presence of multiple stones, use of biliary stents, alcohol consumption, history of biliary tract operations, presence of CBD stenosis, and endoscopic papillary balloon dilation. The RF model outperformed XGBoost and LR in terms of AUC, accuracy, recall, precision, F1-score, and DCA. The SHAP summary plot, waterfall plot, and force plot provided both overall and local explanations of the RF model. Thi

Abstract

To construct predictive models for the recurrence of common bile duct stones (CBDS) following endoscopic retrograde cholangiopancreatography (ERCP). This retrospective study analyzed data from 1,130 patients who were randomly divided into a training set (70%) and a test set (30%). Feature selection was performed using the boruta algorithm and multivariable logistic regression (LR), followed by addressing data imbalance through the Synthetic Minority Over-sampling Technique (SMOTE). Predictive models were developed utilizing random forest (RF), extreme gradient boosting (XGBoost), and LR. We optimized these models through random search and ten-fold cross-validation to identify the best parameters. After model development, we compared their area under the curve (AUC), accuracy, recall, precision, F1-score, and decision curve analysis (DCA) to select the most optimal model. Ultimately, the optimal model was interpreted using shapley additive explanations (SHAP). Eight risk factors were identified and used to construct the predictive model, including clinical course, stone diameter, presence of multiple stones, use of biliary stents, alcohol consumption, history of biliary tract operations, presence of CBD stenosis, and endoscopic papillary balloon dilation. The RF model outperformed XGBoost and LR in terms of AUC, accuracy, recall, precision, F1-score, and DCA. The SHAP summary plot, waterfall plot, and force plot provided both overall and local explanations of the RF model. This study successfully identifies high-risk individuals for recurrent CBDS post-ERCP and offers valuable insights for machine learning-assisted clinical decision-making.

Educational only
This information is for general education and is not medical advice. Always talk to a licensed U.S. clinician about your situation, medications, or treatment decisions.