Optimizing clinical prediction model for new-onset atrial fibrillation in critically ill patient: Based on machine learning - Da-cheng Wang; Xin-yuan Zhang; Xiao-huan Zhuang; Yan Zhuang (PLoS ONE, 2025)
Background New-onset atrial fibrillation (NOAF) increases the risk of embolism and sudden death in critically ill patients; however, limited data exist attempting to identify modifiable risk factors and predict the incidence of NOAF. We aimed to investigate the risk factors for NOAF and develop an optimized clinical prediction model based on machine learning algorithms. Materials and methods Data from patients admitted to the intensive care unit (ICU) of the Affiliated Hospital of Nanjing University of Chinese Medicine from August 2019 to January 2022 were retrospectively analyzed. LASSO regression and Random Forest (RF) algorithms were used to screen predictive variables. Logistic Regression, RF, Gradient Boosting and Support Vector Machine models were constructed to evaluate the recognition ability of different machine learning algorithms. The confusion matrix and calibration curve were used to assess the degree of accuracy of the four models. Decision curve analysis (DCA) was conducted to evaluate the utility of the model in decision-making. The net reclassification index (NRI) and integrated discrimination improvement (IDI) were also calculated to evaluate the performance of the models. The learning curves of the four models were plotted to evaluate the precision of different models. The SHapley Additive exPlanations (SHAP) was used to explain the supreme-performing model. Results In total, 417 patients were enrolled in the study, and 333 patients were allocated to the training group and 84 to the validation group. The baseline characteristic distributions were similar between the two groups. Age, heart rate, mean arterial pressure, activated partial thromboplastin time, and brain natriuretic peptide were revealed as independent predictors of NOAF by LASSO regression and the RF algorithm. The RF model had the best performance, with the area under the receiver operator characteristic curve (AUROC) of 0.758, the area under the precision-recall curve (AUPRC) of 0.524, and accuracy of 0.735 in the training set, paralleled by AUROC of 0.796, AUPRC of 0.686, and accuracy of 0.702 in the validation set. The confusion matrix and calibration curves showed that RF had the best performance. DCAs also showed that the RF model provided the highest net benefit in the clinical setting. The NRI results showed that the RF significantly improved reclassification ability compared to the baseline model (NRI = 0.38). The IDI results further demonstrated a moderate improvement in discrimination ability for the RF (IDI = 0.033) compared to the baseline. The learning curves revealed that RF also showed superior performance. SHAP could be used visualized individual NOAF risk predicted by the model. Conclusions The RF model exhibited the best performance in predicting NOAF in critically ill patients and has the potential to help clinicians identify high-risk patients and guide clinical decision making.