Interpretable machine learning for the early prediction of acute kidney injury in preterm infants in the neonatal intensive care unit Authors: Ding Liu, Jun Lyu, Fang Yang Published: 2025 ABSTRACT AbstractAcute kidney injury (AKI) is a serious complication in preterm infants admitted to neonatal intensive care units (NICUs), contributing to high mortality and long-term morbidity. We conducted a retrospective cohort study including 2,473 preterm infants from the MIMIC-III database. An extreme gradient boosting (XGBoost) model was developed and compared with six other machine learning algorithms as well as the Score for Neonatal Acute Physiology II (SNAP-II). Feature selection was conducted using the Boruta algorithm. Model performance was assessed using the area under the precision-recall curve (AUC-PR), calibration plots, and decision curve analysis. SHapley Additive exPlanations (SHAP) were applied to elucidate feature importance and interactions. The XGBoost model achieved superior discrimination (AUC: 0.922 and AUC-PR: 0.618). Sensitivity analyses using multiple imputation and class weighting affirmed robustness. SHAP analysis revealed SNAP-II and first-day urine output as the most influential predictors. Interaction analysis revealed that higher SNAP-II levels combined with lower birth weight and lower urine output combined with positive fluid balance synergistically increased the risk of AKI. We identified two actionable thresholds to guide clinical use: 0.146 (Youden Index) for enhanced monitoring and 0.88 (positive predictive value ≥ 80%) for prompt nephrology consultation. We developed and internally validated an interpretable XGBoost-based model that predicts AKI in preterm infants within 7 days of NICU admission. Furthermore, it represents the first application of such a model for risk stratification and the development of a lightweight calculation tool (Shiny) to facilitate early kidney-protective interventions and risk management in this vulnerable population.Keywords: Preterm infants, acute kidney injury, machine learning, SHAP, XGBoost Introduction Acute kidney injury (AKI) causes a decline in the glomerular filtration rate (GFR) in preterm infants, leading to the retention of nitrogenous compounds (e.g., urea). This results in disturbances in fluid volume regulation, electrolyte balance, and acid-base equilibrium, which may result in oliguria or anuria [1]. The prevalence of neonatal AKI ranges from 6.5% to 17.7%, with rates rising to 18%–52% in critically ill neonates [2]. The incidence of AKI in preterm infants varies widely, ranging from 2.4% to 56% [3,4]. The Assessment of Worldwide Acute Kidney Epidemiology in Neonates (AWAKEN) study found that AKI occurred in 30% of 2,022 critically ill neonates and was associated with a 4.6-fold increase in the adjusted odds of mortality [5]. Another study reported that lower gestational age is associated with more severe kidney damage and higher mortality rates [6]. Notably, mild neonatal AKI is often reversible and has minimal long-term effects on infant prognosis and quality of life [6]. However, severe AKI is often associated with poor prognosis, extended hospital stays, and increased medical expenses. Newborns are particularly vulnerable to AKI due to undeveloped renal systems, which impair their ability to effectively filter, reabsorb, and concentrate fluids [7]. Additionally, neonatal renal hemodynamics and perfusion undergo significant postnatal shifts, with perfusion increasing from 2.5% to 4% of the total cardiac output at birth to nearly 10% by day 7. Adult kidneys receive significantly greater perfusion than neonatal kidneys, with renal blood flow representing 20%–25% of the total cardiac output. Newborns exposed to various risk factors are particularly vulnerable to renal hemodynamic alterations, which can trigger AKI [8]. Contemporary research [9–18] has identified several risk factors contributing to the pathogenesis of neonatal AKI. These include intrinsic factors (e.g., prematurity, low birth weight), perinatal complications (e.g., asphyxia, respiratory distress requiring mechanical ventilation), acquired conditions (e.g., sepsis, necrotizing enterocolitis, hyperbilirubinemia), cardiovascular abnormalities (e.g., patent ductus arteriosus, cardiac surgery), and iatrogenic exposures (e.g., ventilation, nephrotoxic medications such as vancomycin). Longitudinal cohort studies have shown that neonatal AKI is a significant predictor of progressive renal dysfunction and persistent blood pressure elevation in pediatric and adult populations. Research indicates that 27%–66.7% of preterm infants who survive AKI may develop chronic kidney disease as adults [19]. Schiffl et al. [20] showed that 14% of their study cohort progressed to chronic kidney disease within a 5-year follow-up period, with persistent microalbuminuria lasting up to 4 years after the initial AKI episode [21]. A longitudinal study by Starzec et al. [22] tracked extremely preterm infants through adolescence, with an 11-year follow-up. The study documented persistent nephrological sequelae, including renal hypoplasia, elevated blood urea nitrogen concentrations, and a progressive decline in GFR. The main clinical methods for assessing kidney function are serum creatinine (SCr) levels and urine output. Neonatal SCr values in the early postnatal period (0–72 h) are strongly correlated with maternal levels. Because of the functional reserve of the kidney, SCr levels typically increase 1–2 days post-injury, during which 25%–50% of kidney function may already be compromised [23]. In preterm infants, body fluid accounts for 80% of their body weight, and their tubular concentration and dilution functions are not yet fully developed. Consequently, neonatal AKI often occurs without significant changes in urine output [24]. Even when urine output is normal or increased, SCr levels are substantially elevated, making both markers less reliable for diagnosing AKI. In contrast, the diagnostic reliability of serum cystatin C (CysC) for AKI in preterm infants with respiratory distress syndrome is not affected by sex, muscular development, or postnatal age, making it a preferred biomarker in neonatal intensive care units (NICUs) [25–27]. However, Saeidi et al. [28] observed a negative correlation between the CysC levels and gestational age in these infants. The predictive potential of CysC for AKI requires further investigation. Given the limitations of traditional assessment methods, novel biological markers have been introduced in recent research. These markers show exceptional diagnostic precision for the early and noninvasive identification of AKI. Current biomarker research highlights several molecular classes for AKI detection, including epigenetic regulators (miR-22-3p, urinary miR-26b), stress-response proteins (NGAL, kidney injury molecule-1; KIM-1), and cellular senescence indicators (tissue inhibitor of metalloproteinases-2 (TIMP-2)/insulin-like growth factor binding protein 7 (IGFBP7)) [29–33]. However, the application of these methods in clinical practice is challenging due to their high costs and stringent testing protocols. The Score for the Neonatal Acute Physiology (SNAP)-II scoring system has significant prognostic value in predicting multiple severe neonatal conditions. For example, Snoek et al. [34] validated the dual utility of this scoring system: stratifying mortality risk and guiding extracorporeal membrane oxygenation intervention for patients with congenital diaphragmatic hernia. Nakwan et al. [35] identified a critical SNAP-II threshold of 43, above which neonates with persistent pulmonary hypertension experience significantly high mortality rates. However, research on the use of SNAP-II for predicting AKI in preterm infants remains limited. Conventional analytical approaches, such as Cox regression modeling and logistic regression (LR) analysis, have traditionally been used for stratifying the risk of AKI in patients with sepsis. However, these models struggle to capture the intricate nonlinear relationships between variables and outcomes. Advancements in statistical modeling and computational technology have significantly increased the use of machine learning (ML). Clinicians are increasingly recognizing the potential of ML to enhance predictive accuracy. Emerging ML techniques outperform traditional logistic and Cox regression in predictive models under various conditions [36,37]. Chiofolo et al. [37] developed an automated continuous random forest (RF) algorithm for AKI prediction in intensive care unit populations. The proposed algorithm demonstrated superior performance in the early identification of high-risk patients. Similarly, Le et al. [38] pioneered a deep learning framework using a convolutional neural network architecture for early AKI detection in critical care settings. Although ML has transformed AKI prediction in adults, its application in neonatal nephrology remains significantly underdeveloped. Although SCr and urine output are the current gold standards for diagnosing neonatal AKI according to the Kidney Disease: Improving Global Outcomes (KDIGO) criteria, these conventional markers have notable limitations, especially for early detection. For example, SCr elevation often occurs after AKI onset, and many neonatal AKI cases are non-oliguric, making early identification challenging. Despite these limitations, SCr and urine output remain the most feasible diagnostic references in retrospective databases, such as Medical Information Mart for Intensive Care III (MIMIC-III). More sensitive biomarkers, such as NGAL and CysC, are not routinely available and were not included in this study. Therefore, although our model was trained using these clinical standards, its primary aim was not to outperform them diagnostically but to predict AKI risk earlier by incorporating a broader range of early-phase clinical indicators. This approach can inform clinical decision-making before the abnormality of traditional markers, thus improving the timeliness of intervention. Although ML approaches have shown promise in adults and children, evidence supporting their use in preterm infants remains scarce. Preterm infants have distinct physiological characteristics, risk profiles, and clinical trajectories, which require tailored predictive models that address these unique factors. Recent large-scale studies, including multicenter cohorts and dedicated neonatal frameworks, have begun exploring artificial intelligence or ML for neonatal and pediatric AKI prediction [39,40]. However, most studies have focused on mixed-age populations or lack interpretability specific to preterm infants. Furthermore, the integration of such a model with a practical clinical tool, such as a lightweight Shiny-based calculator for risk stratification and early kidney-protective interventions, has not been previously reported. This study therefore represents the first effort to develop and implement an interpretable machine learning model for preterm infant AKI, combining predictive performance with actionable bedside decision support. Methods Data source The clinical data of preterm infants were retrieved from the MIMIC-III database [41], a publicly accessible dataset containing anonymized ICU records from the Beth Israel Deaconess Medical Center in Boston, Massachusetts. Using structured query language, we extracted a wide range of patient-specific variables, including demographic details, physiological measurements, laboratory findings, fluid intake and output records, pharmacological interventions, hospitalization duration, discharge details, and survival outcomes. Database access was granted following completion of Collaborative Institutional Training Initiative human subjects research training (Certification #55551396). Participants Participants were eligible if they were diagnosed with prematurity, as defined by the following International Classification of Diseases, 9th Revision codes: ‘76521,’ ‘76522,’ ‘76523,’ ‘76524,’ ‘76525,’ ‘76526,’ ‘76527,’ ‘76528,’ ‘76502,’ ‘76512,’ ‘76503,’ ‘76513,’ ‘76501,’ ‘76511,’ ‘76504,’ ‘76514,’ ‘76505,’ ‘76515,’ ‘76506,’ ‘76516,’ ‘76507,’ ‘76517,’ ‘76508,’ and ‘76518.’ AKI was defined according to the KDIGO clinical guidelines [42] and identified as occurring between the second and seventh day after NICU admission. The risk assessment for AKI in preterm infants during the first week after birth will be calculated at 6, 12, and 48 h and within 7 days postnatally. All laboratory variables were collected within the first 24 h following admission to the NICU. Participants who left the NICU within 48 h were excluded. Patients with missing data exceeding 20% were excluded from the analysis (Figure 1). Flowchart illustrating the patient selection process. Data extraction The study utilized clinical data extracted from the MIMIC-III database, which included the following variables: (1) demographic information (sex, age, and ethnicity); (2) comorbidities (suspected infections, neonatal jaundice, apnea, septicemia, patent ductus arteriosus, respiratory issues, bradycardia, and RDS in newborns); (3) vital signs (heart rate, temperature [T], minimum and first weights, and LOS); and (4) laboratory parameters (hematocrit, hemoglobin, and platelet and white blood cell counts, both minimum and maximum). All treatment variables were time-stamped to ensure they occurred prior to AKI diagnosis, thereby avoiding reverse causality. First-day fluid balance, calculated as (intake – output)/birth weight × 100%, were also included [43]. The positive and negative fluid balances were defined as intake > output and intake < output, respectively. Disease severity was assessed using the SNAP-II scoring system [44]. Multiple imputation by chained equations (MICE) was applied to the remaining dataset to handle missing data while preserving statistical validity [45]. Multiple plausible substitutes were used for each missing value to capture the inherent uncertainty associated with missing information. These estimates were then aggregated to produce a single, reliable coefficient that accounted for the uncertainty introduced by the missing data. Multiple imputation was more effective than single imputation in avoiding underestimation of variance in the estimated coefficients. Statistical analysis Continuous variables that did not follow a normal distribution were described using median values and interquartile ranges. Group comparisons were performed using the Wilcoxon rank-sum test. Continuous variables with a normal distribution are presented as the mean ± standard deviation and were assessed using independent samples t-tests. Categorical data were summarized as counts and percentages, and comparisons between groups were conducted using either the chi-square test or Fisher’s exact test, depending on the characteristics of the data. The Boruta algorithm was used for feature selection, and the importance (Z-values) of actual features were iteratively compared to randomly permuted shadow features using RF models. A feature was deemed important if its Z-value consistently surpassed that of all shadow features across iterations [46]. A comparative analysis was conducted using seven predefined algorithm classes: LR, KNN, SVM, DT, RF, XGBoost, and NNET. The training and validation datasets were cross-validated 10 times to ensure robustness and prevent overfitting. The dataset was divided into 10 segments, seven for training and three for validation. The validation set was employed to evaluate and compare the performance of the final models. The prevalence of AKI in the study cohort was approximately 10.7%, resulting in class imbalance. To address this, we applied class rebalancing techniques, such as SMOTE and class weighting, depending on the model architecture. For performance evaluation, we reported recall, specificity, precision, Brier score, and F1 score. Given the dataset’s imbalanced nature, we also constructed and compared precision-recall (PR) curves, which offer a more informative assessment of classifier performance in skewed data scenarios. Model performance was evaluated using recall, specificity, precision, accuracy, F1 score, and area under the precision-recall curve (AUC-PR), all derived from confusion matrices. Bootstrap calibration plots and decision curve analysis were used to assess reliability and utility. R 4.2.2 was used for the analyses (significance: p < 0.05, two-tailed). To address the interpretability challenge of ML models, we applied SHAP, which assigns locally accurate and consistent importance values to each feature in individual predictions [47]. SHAP quantifies the contribution of a feature by computing its marginal effect across all subsets of features excluding itself, offering a unified interpretive framework for various ML algorithms. Clinically actionable decision thresholds were determined from the XGBoost model using the Youden index to balance sensitivity and specificity, as well as a threshold based on positive predictive value (PPV) to identify high-risk patients. These thresholds were then mapped to corresponding clinical actions, such as initiating nephrology consultation or implementing nephrotoxin stewardship. To promote reproducibility and clinical translation, we have made the complete code for data preprocessing and model development publicly available. Furthermore, we developed an interactive web calculator using the R Shiny framework, allowing for individual patient risk assessment. Results Baseline characteristics Among the 2,473 preterm infants analyzed, 265 (10.7%) developed AKI. Demographic analysis revealed comparable sex and racial composition between the groups (p > 0.05). However, the AKI population exhibited markedly reduced mean birth weight and gestational age (both p < 0.001). The AKI cohort had significantly higher hospital mortality rates than the non-AKI control (2.3% vs. 0.8%, p = 0.023). Additionally, the AKI cohort had a greater prevalence of positive fluid balance (90.2% vs. 83.9%, p = 0.007) than the non-AKI control. These infants also had higher fluid overload percentages and significantly reduced first-day urine output (median: 112 mL vs. 176 mL, p < 0.001). Interestingly, birth weight and the lowest recorded weight were higher in the AKI population (p = 0.006 and p = 0.067, respectively), possibly indicating fluid retention. Laboratory tests revealed lower minimum hematocrit (p = 0.013) and elevated minimum and maximum white blood cell counts (p = 0.003 and p < 0.001) in the AKI group. The severity of illness, as measured by the SNAP-II score, was also higher in AKI cases (median: 8.0 vs. 3.0, p < 0.001). AKI neonates had 1.9-fold greater ventilator use (p = 0.001), 2.5-fold increased vasopressor administration (p = 0.001), 2.2-fold higher NSAID exposure (p < 0.001), 7.5-fold greater diuretic utilization (p = 0.001), and 1.3-fold more antibiotic therapy (p = 0.044) than non-AKI controls. Additionally, the AKI group had a higher incidence of comorbidities, such as patent ductus arteriosus (20.8% vs. 11.4%, p < 0.001), neonatal sepsis (10.2% vs. 6.8%, p = 0.046), primary apnea (31.3% vs. 37.5%, p = 0.049), and transient electrolyte disturbances (5.7% vs. 3.1%, p = 0.031) (Table 1). Table 1.Baseline characteristics of premature newborns.CharacteristicsALL (n = 2473)Non-AKI (n = 2208)AKI (n = 265)P-valueSex 0.375Female, n (%)1146 (46.3)1030 (46.6)116 (43.8) Male, n (%)1327 (53.7)1178 (53.4)149 (56.2) Ethnicity, n (%) 0.765White1556 (62.9)1384 (62.7)172 (64.9) Black284 (11.5)256 (11.6)28 (10.6) Others633 (25.5)568 (25.7)65 (24.5) Birthweight classification, n (%) 0.000ELBW249 (10.1)213 (9.6)36 (13.6) VLBW469 (19.0)442 (20.0)27 (10.2) 1500–2499 g, premature infants1349 (54.5)1206 (54.6)143 (54.0) ≥ 2500 g, premature infants358 (14.5)303 (13.7)55 (20.8) Gestational age, n (%) 0.000< 28 weeks300 (12.1)254 (11.5)46 (17.4) 29–32 weeks712 (28.8)667 (30.2)45 (17.0) 33–34 weeks763 (30.9)674 (30.5)89 (33.6) 35–36 weeks342 (13.8)286 (13.0)56 (21.1) Mode of delivery, n (%) Cesarean section, live birth1679 (67.9)150568.2)174 (65.7)0.522Vaginal delivery, live birth568 (23.0)506 (22.9)62 (23.4) Unknown226 (9.1)197 (8.9)29 (10.9) Fetal number, n (%) 0.355Single birth, live birth1348 (54.5)1193 (54.0)155 (58.5) Twin or multiple births, all live births977 (39.5)880 (39.9)97 (36.6) Unknown148 (6.0)135 (6.1)13 (4.9) Hospital mortality, n (%)24 (1.0)18 (0.8)6 (2.3)0.023Fluid balance status 0.007Positive balance2091 (84.6)1852 (83.9)239 (90.2) Negative balance384 (15.4)356 (16.1)26 (9.8) Fluid balance (%)26.5 (19.09, 43.91)24.93 (7.78, 42.24)38.24 (23.03, 55.16)0.000First-day urine output (mL)172.00 (108.00, 238.00)176.00 (118.00, 244.00)112.00 (59.00, 190.00)0.000Hospital stay duration (day)16.64 (8.55, 37.30)16.77 (8.65, 37.45)15.03 (7.97, 375.67)0.423Lowest weight (kg)1.75 (1.27, 2.18)1.73 (1.27, 2.16)1.92 (1.44, 2.33)0.067Birth weight (kg)1.86 (1.39, 2.28)1.85 (1.39, 2.26)1.99 (1.55, 2.42)0.006Temperature (°C)36.50 (36.20, 36.60)36.40 ± 0.9136.18 ± 3.240.262Heart rate (beats/min)156.01 ± 16.23155.86 ± 16.27157.28 ± 15.860.179HEMATOCRIT_min (%)48.12 ± 6.7048.24 ± 6.6347.16 ± 7.170.013HEMATOCRIT_max (%)48.88 ± 6.1848.95 ± 6.1548.26 ± 6.470.087HEMOGLOBIN_min (g/dl)16.10 ± 2.2116.13 ± 2.2015.88 ± 2.360.092HEMOGLOBIN_max (g/dL)16.28 ± 2.0516.30 ± 2.0416.13 ± 2.180.183PLATELET_min (K/UL)259.58 ± 82.63260.42 ± 81.99252.54 ± 87.620.142PLATELET_max (K/UL)267.39 ± 82.63267.76 ± 76.21264.24 ± 76.370.477WBC_min (K/UL)10.30 (7.70, 13.40)10.20 (7.60, 13.20)11.40 (8.30, 14.9)0.003WBC_max (K/UL)10.60 (8.1, 13.60)10.45 (8.00, 13.40)11.80 (8.9, 15.4)0.000SNAP_II3.00 (0, 8.00)3.00 (0.00, 3.00)8.00 (5.00, 20.00)0.000Apgar 1 min8.00 (7.00, 8.00)8.0 (07.00, 8.00)7.00 (6.0, 8.00)0.198Apgar 5 min8.00 (8.00, 9.00)8.00 (8.00, 9.00)8.00 (7.00, 9.00)0.110Ventilator, n (%)387 (15.6)315 (14.3)72 (27.2)0.001Vasopressors, n (%)94 (3.8)72 (3.3)22 (8.3)0.001NSAIDs, n (%)201 (8.1)159 (7.2)42 (15.8)0.000Surfactant, n (%)995 (40.2)885 (40.1)110 (41.5)0.654Methylxanthines, n (%)363 (14.7)326 (14.6)37 (14.0)0.727Diuretics, n (%)9 (0.4)5 (0.2)4 (1.5)0.001Antibiotic, n (%)1482 (59.9)1308 (59.2)174 (65.7)0.044Blood culture_flag, n (%)121 (4.9)103 (4.7)18 (6.8)0.129RDS, n (%)1115 (45.1)997 (45.2)118 (44.5)0.847Suspected infection cases under observation, n (%)1780 (72.0)1599 (72.4)1681 (68.3)0.159Prematurity-related jaundice, n (%)1994 (80.6)1782 (80.7)212 (80.0)0.783Unexplained neonatal jaundice, n (%)68 (2.7)64 (2.9)4 (1.5)0.191Patent ductus arteriosus, n (%)307 (12.4)225 (11.4)55 (20.8)0.000Neonatal primary apnea, n (%)911 (36.8)828 (37.5)83 (31.3)0.049Neonatal bradycardia, n (%)537 (21.7)483 (21.9)54 (20.4)0.576Other specified conditions originating in the perinatal period, n (%)223 (9.04)193 (8.7)30 (11.3)0.166Transitory tachypnea of newborn, n (%)293 (11.8)265 (12.0)28 (10.6)0.494Intraventricular hemorrhage, n (%)168 (6.8)149 (6.7)19 (7.2)0.797Neonatal sepsis, n (%)178 (7.2)151 (6.8)27 (10.2)0.046Anemia of prematurity, n (%)349 (14.1)314 (14.2)35 (13.2)0.654Other transitory neonatal electrolyte disturbances, n (%)84 (3.4)69 (3.1)15 (5.7)0.031Neonatal hypoglycemia, n (%)161 (6.5)149 (6.7)12 (4.5)0.166Other neonatal apnea, n (%)124 (5.0)114 (5.2)10 (3.8)0.327Secondary ostium secundum atrial septal defect, n (%)75 (3.0)88 (4.0)17 (6.4)0.064Genetic or metabolic disorders, n (%)105 (4.2)63 (2.9)12 (4.5)0.133Continuous variables are presented as medians with interquartile ranges (IQR), while categorical variables are expressed as counts with percentages. ELBW: Extremely low birth weight (< 1000 g), VLBW: Very low birth weight (1000–1500 g), SNAP-II: Score for neonatal acute physiology II, WBC: White blood cell, NSAIDs: Non-steroidal anti-inflammatory drugs, RDS: Respiratory distress syndrome. Baseline characteristics of premature newborns. Continuous variables are presented as medians with interquartile ranges (IQR), while categorical variables are expressed as counts with percentages. ELBW: Extremely low birth weight (< 1000 g), VLBW: Very low birth weight (1000–1500 g), SNAP-II: Score for neonatal acute physiology II, WBC: White blood cell, NSAIDs: Non-steroidal anti-inflammatory drugs, RDS: Respiratory distress syndrome. Comparison of model performance Using the Boruta algorithm for feature selection, 26 out of 50 candidate variables were selected. (Figure 2). Key variable selection in preterm infants using the Boruta algorithm. Hematologic parameters: lowest and highest hematocrit, hemoglobin, platelet count, and white blood cell count. Clinical and physiological variables: SNAP-II score, length of stay (LOS), urine output on the first day after birth (FirstUrineOutput), birth weight (firstweight), and lowest postnatal weight (min_weight). Comorbidities: respiratory distress syndrome (Respiratory_distress_syndrome_in_newborn), anemia of prematurity (Anemia_of_prematurity), transitory tachypnea of newborn (Transitory_tachypnea_of_newborn), and patent ductus arteriosus (Patent_ductus_arteriosus). Treatment-related factors: pulmonary surfactant administration (PS_flag), NSAID use (NSAIDs), vasopressor therapy (vasoentdurationssingle_flag), mechanical ventilation (ventdurationssingle_flag), diuretics (diuretics_flag), methylxanthine drugs (methylxanthine_flag), and antibiotics (antibiotics_flag). Other predictors: birth weight classification (Weight_label) and gestational age (GA). The XGBoost model demonstrated superior overall performance; it achieved the highest AUC (0.922), indicating excellent discriminative ability, coupled with the highest accuracy (0.942) and the lowest Brier score (0.051), signifying well-calibrated probabilistic predictions. It also maintained a strong balance between sensitivity (0.632) and precision (0.705), resulting in a high F1-Score (0.667) (Table 2). The ROC curve analysis in Figure 3 illustrates the performance of eight ML models in predicting neonatal AKI. The XGBoost model achieved the highest AUC, followed by RF and DT. In contrast, the baseline SNAP model and KNN demonstrated the lowest AUC values, suggesting limited discriminatory ability in identifying AKI cases. Decision curve analysis (DCA) confirmed the clinical superiority of the XGBoost model, with net benefit values consistently above the testing and intervention axes for threshold probabilities (Figure 4). Table 2.Comparative performance of machine learning models for neonatal AKI prediction.ModelAUCSensitivitySpecificityPrecisionAccuracyF1-ScoreAUC-PRBrier-scoreLR0.8120.2060.9700.4120.9000.2750.3010.078XGB0.9220.6320.9730.7050.9420.6670.6180.051RF0.8650.1030.9930.5830.9110.1750.5390.063SVM0.7520.0290.9970.5000.9080.0560.3100.075NNET0.8020.0001.000NA0.908NA0.2130.084KNN0.6360.0740.9820.2940.8990.1180.1270.098DT0.8500.6770.9630.6480.9370.6620.5170.053SNAP-II0.7870.0290.9790.1250.8920.0480.2260.081Table summarizing the predictive performance of eight models for neonatal AKI. LR: Logistic regression, KNN: k-nearest neighbors, SVM: Support vector machine, XGBoost: Extreme gradient boosting, DT: Decision tree, RF: Random forest, NNET: Artificial neural network, SNAP-II: Score for neonatal acute physiology II. AUC PR refers to the area under the precision-recall curve. Comparative performance of machine learning models for neonatal AKI prediction. Table summarizing the predictive performance of eight models for neonatal AKI. LR: Logistic regression, KNN: k-nearest neighbors, SVM: Support vector machine, XGBoost: Extreme gradient boosting, DT: Decision tree, RF: Random forest, NNET: Artificial neural network, SNAP-II: Score for neonatal acute physiology II. AUC PR refers to the area under the precision-recall curve. Comparison of the performance of different models. The X-axis represents recall (sensitivity), and the Y-axis represents precision (positive predictive value). Logistic regression (LR), k-nearest neighbors (KNN), support vector machines (SVM), extreme gradient boosting (XGBoost), and the Score for Neonatal Acute Physiology-II (SNAP-II). Decision curve analysis for comparative models. The model’s net benefit is compared with two reference strategies: a null strategy (flat line), representing no AKI interventions, and a treat-all strategy (sloped grey line), representing universal intervention for all infants. Comparison of models with and without treatment features: To ensure that treatment variables were not downstream of incipient AKI, all treatment exposures were time-aligned prior to AKI diagnosis. The XGBoost model achieved strong performance both with treatment features (AUC = 0.922, PR-AUC = 0.618) and without them (AUC = 0.886, PR-AUC = 0.636). Minimal changes in PR-AUC (ΔPR-AUC = −0.005 and −0.009, respectively) and well-calibrated probability outputs (Brier score: 0.051 and 0.050) indicate that treatment variables, while informative, were not the primary drivers of predictive accuracy (Table 3). Table 3.Model performance with vs. Without treatment features.ModelFeature SetAUCSensitivitySpecificityPrecisionAUC-PRBrierΔAUC-PRXGBWith treatments0.9220.6320.9730.7050.6180.051–XGBWithout treatments0.8860.6290.9820.8240.6360.054−0.018LRWith treatments0.8120.2060.9700.4120.3010.078–LRWithout treatments0.7990.0670.9860.4000.2760.094−0.026 Model performance with vs. Without treatment features. Class imbalance evaluation: Among strategies to address class imbalance, class weighting provided the most effective and stable performance for tree-based models, enabling XGBoost to achieve optimal sensitivity (0.676), specificity (0.948), and PR-AUC (0.626) with minimal ΔPR-AUC (–0.005). In contrast, SMOTE substantially increased false positive rates, and focal loss resulted in poorly calibrated probability outputs (Table 4). Table 4.Performance comparison of class imbalance handling strategies for XGBoost.MethodSensitivitySpecificityPrecisionAUC-PRBrier ScoreΔAUC-PRClass weighting0.6770.9480.5680.6260.064−0.005SMOTE0.7350.8960.4170.5640.093−0.054Focal loss0.3680.9900.7810.58028.982−0.038None (baseline)0.6320.9670.6620.618 0.052 – Performance comparison of class imbalance handling strategies for XGBoost. Sensitivity analysis for missing data: Comparison of multiple imputation by chained equations (MICE, n = 2,473) with complete-case analysis (n = 1,739) demonstrated that MICE produced superior and more stable model performance (e.g. XGBoost AUC: 0.922 vs. 0.916). Therefore, MICE was retained for the primary analysis to maximize statistical power and minimize potential selection bias (Table 5). Table 5.Sensitivity analysis: MICE vs. complete-case analysis.MethodSample SizeAUCAUC-PRSensitivitySpecificityMICE2,473 0.922 0.6180.6320.973Complete-Case1,7390.916 0.726 0.600 0.985 Sensitivity analysis: MICE vs. complete-case analysis. The XGBoost model ranks the features according to their importance, as shown in Figure 5. The most significant features contributing to AKI in preterm infants were the SNAP-II score, first-day urine output. Two analytical approaches were used to identify the most influential features of the proposed predictive model. Feature importance rankings in the XGBoost model for AKI prediction. Scores for Neonatal Acute Physiology-II (SNAP-II) and First-day urine output (FirstUrineOutput) were identified as the most influential predictors of AKI risk. A SHAP summary plot (Figure 6) was generated to rank and visualize the top 20 predictive features in the proposed XGBoost model. This plot effectively demonstrates the relationship between the feature values (high and low ranges) and their corresponding SHAP values across the training dataset. Our analysis revealed a clear positive association between high SHAP values for certain features and an increased risk of AKI. This offered valuable insights into the predictive reasoning of the model. SHAP summary plot: feature impact on AKI prediction risk. Features are ranked on the vertical axis in descending order of importance, while the horizontal axis displays SHAP values representing the magnitude and direction of each feature’s impact on the model output. Positive SHAP values indicate an increased predicted risk of AKI, whereas negative values suggest a protective effect. Each dot represents a single observation, with color corresponding to the actual feature value (red = higher, blue = lower), enabling intuitive interpretation of feature influence patterns. SNAP-II score: Higher SNAP-II scores were associated with increased SHAP values, indicating higher predicted risk of AKI. The relationship was nonlinear, with SHAP values increasing notably when SNAP-II exceeded approximately 10–15 (Figure 7). Birth weight appeared to modulate this effect, with lower birth weight amplifying the impact of SNAP-II. SHAP Interaction values: SNAP-II and first weight. X-axis: SNAP-II (Score for Neonatal Acute Physiology, Version II). Y-axis: SHAP Interaction Value. Represents the combined marginal effect of the two features on the model’s prediction. Positive values increase the predicted outcome (e.g., risk of an adverse event). Color Bar: Represents the value of the infant’s first recorded weight (firstweight). Lighter colors indicate higher birth weights, while darker colors (blue) indicate lower birth weights. The black dashed line represents the overall trend with a 95% confidence interval (gray shading). First day urine output: An inverse relationship was observed between urine output on the first day and its SHAP values, indicating that lower urine output elevated predicted AKI risk. This effect was stronger under positive fluid balance (red points), suggesting a synergistic interaction (Figure 8). SHAP Interaction plot between first urine output and fluid balance status. Each point represents an individual patient. The x-axis corresponds to urine output on the first day of life(FirstUrineOutput), and the y-axis represents the SHAP value for FirstUrineOutput, reflecting its contribution to the model prediction. Point color indicates fluid balance status: red denotes positive fluid balance (fluid intake > fluid output), and blue denotes negative fluid balance (fluid output > fluid intake). NSAID exposure: Neonates who received NSAIDs (value = 1) showed higher SHAP values compared with those who did not (value = 0), indicating increased predicted AKI risk. This effect was more pronounced in infants with higher SNAP-II scores (red points), whereas absence of NSAID exposure corresponded to SHAP values near zero (Figure 9). SHAP Interaction values: NSAIDs and SNAP-II. The x-axis indicates NSAID administration (0 = not used, 1 = used), and the y-axis shows the SHAP value for NSAID use, representing its contribution to the model prediction. The color gradient reflects the SNAP-II score, a measure of illness severity, with blue indicating lower severity and red indicating higher severity To translate model predictions into clinical practice, actionable decision thresholds were defined from the XGBoost model. The Youden Index threshold was 0.146, corresponding to balanced sensitivity and specificity for identifying a broad at-risk population suitable for enhanced monitoring. A high-precision threshold (PPV ≥ 0.8) was 0.88, identifying a smaller cohort with a very high likelihood of AKI, appropriate for triggering resource-intensive interventions, such as nephrology consultation. Based on these thresholds, a clinical intervention flow chart was developed to stratify patients into low-, moderate-, and high-risk groups, with recommended corresponding actions (Figure 10). Clinical intervention pathway based on XGBoost-predicted AKI risk. We have developed a user-friendly, lightweight web application using the R Shiny framework. This tool allows clinicians and researchers to input individual patient characteristics and obtain real-time predictions of AKI risk based on our best performingXGBoost model. The application can be accessed at: https://dingliu.shinyapps.io/neonatal-aki-calculator/ Discussion In this study, we make a novel contribution to neonatal AKI prediction by systematically evaluating and comparing seven ML algorithms against the conventional SNAP-II scoring system in preterm infants using the MIMIC-III dataset. The ML models demonstrated good discrimination and calibration. However, their clinical utility was limited because prediction models often face implementation barriers when optimal decision thresholds exceed clinically actionable probability ranges or operational feasibility constraints [48]. Using DCA to assess clinical relevance, we found that XGBoost exhibited excellent calibration (Brier score = 0.051). This indicates that its predicted probabilities can be directly interpreted as clinical risk estimates. Furthermore, the Boruta algorithm was applied to identify the most significant independent variables, facilitating more effective feature selection. Neonatal AKI demonstrated considerable epidemiological variability, with reported incidence rates ranging from 8% to 24% across different clinical populations, although the true prevalence may be underestimated [49–51]. Approximately 60% of preterm infants with extremely low birth weight develop AKI, with a mortality rate ranging from 10% to 61% [52,53]. Furthermore, recent research has revealed that AKI is a significant factor affecting newborns, particularly preterm infants with low gestational age [54,55]. In our cohort, 11.9% of preterm infants developed AKI in the NICU. The relatively low incidence and high mortality rate of neonatal AKI may be attributed to a lack of attention from healthcare providers, delayed diagnosis, and the complexity of AKI diagnosis in neonates compared with that in adults and older children. The development and promotion of reliable prediction models play a major role in identifying high-risk infants and providing timely and effective interventions. Although traditional scoring systems are valuable for general risk stratification, their accuracy is often limited by subjective clinical judgment and a narrow set of predefined variables [56–58]. Consequently, they may fail to capture the complex, nonlinear interactions underlying the development of AKI in neonates. In contrast, ML approaches leverage multivariate data to provide more robust and individualized predictions, offering clear advantages over conventional severity scores. Recent studies have explored neonatal AKI–specific scoring tools and biomarker-based models, providing important context for interpreting our findings. For example, the STress-Adjusted Risk Z-score (STARZ) neonatal score was developed and externally validated as a dedicated risk stratification tool for neonatal AKI. It achieved excellent performance, with AUCs ranging from 0.93 to 0.96 in the derivation and validation cohorts and sensitivity/specificity exceeding 80%–90% [59–61]. However, despite its strengths, STARZ relies on predefined clinical variables and logistic regression, limiting its adaptability to diverse NICU populations and temporal clinical data compared to more flexible ML frameworks. In parallel, a growing body of research has investigated emerging urinary and serum biomarkers—such as NGAL, cystatin C, IL-18, KIM-1, osteopontin, TIMP-2/IGFBP-7, and β2-microglobulin—as adjuncts for early AKI detection. Recent reviews have highlighted that NGAL, cystatin C, and osteopontin consistently demonstrate strong predictive accuracy (AUC > 0.8) [25,62]. Despite their promise, these biomarkers are not yet widely available in routine NICU practice and were not captured in the MIMIC-III dataset. This underscores a key limitation of retrospective database studies. This study builds on prior approaches by leveraging routinely collected NICU data, applying multiple ML algorithms, and integrating SHAP to improve interpretability. Our comparative analysis revealed the superior predictive performance of XGBoost over conventional regression models. This finding is consistent with prior evidence that XGBoost outperforms LR, SVM, RF, and other ML approaches in AKI prediction [57,58,63]. We performed comprehensive sensitivity analyses, including complete-case vs. MICE and SMOTE vs. class weights vs. focal loss, which collectively confirmed the robustness of our primary findings. We incorporated the SHAP framework to enhance interpretability, which identified the SNAP-II score and early urine output as the strongest contributors to AKI risk in preterm infants. Compared to conventional NICU screening protocols, our model offers clear advantages in terms of timeliness and comprehensiveness. Routine urine output monitoring may miss non-oliguric cases, while KDIGO SCr criteria are delayed by 24–72 h and influenced by maternal levels. Our model enabled earlier risk prediction than traditional markers by integrating SNAP-II scores, urine output, and hematologic parameters within the first 24 h of NICU admission. These findings underscore the clinical value of combining ML with SHAP-based interpretation for the early identification and timely intervention of high-risk preterm infants. Our study identified the SNAP-II score and early urine output as key AKI predictors in preterm infants. The SHAP interaction plot revealed a nonlinear threshold effect, with SNAP-II scores exceeding approximately 10–15 markedly increasing the risk of AKI, particularly in low-birth-weight neonates. This suggests that illness severity and physiological immaturity synergistically contribute to renal vulnerability, with the predicted AKI risk substantially elevated by the combined effect of high SNAP-II and low birth weight. These findings are consistent with prior reports linking high illness severity scores to mortality and renal injury [64,65] and support intensified monitoring in critically ill, physiologically fragile neonates. The SHAP analysis indicated that lower first-day urine output was associated with an increased predicted risk of AKI. This effect was particularly pronounced under positive fluid balance, suggesting that the combination of oliguria and fluid overload synergistically contributes to higher AKI risk. NSAIDs exposure was associated with a significantly increased risk of AKI, with neonates receiving NSAIDs demonstrating higher SHAP values than those who did not. This effect was more pronounced among infants with higher SNAP-II scores, indicating that critically ill neonates are particularly vulnerable to AKI risk-related increases in NSAIDs. This underscores the importance of cautious NSAIDs use and rigorous renal monitoring in high-risk neonates, especially those with greater illness severity. These findings emphasize that integrating illness severity, urine output patterns, fluid balance status, and medication exposure into NICU risk assessment could facilitate earlier recognition of at-risk infants and enable more timely, kidney-protective interventions. Our clinical decision thresholds—a Youden threshold of 0.146 for general risk stratification and a high-risk threshold of 0.88 (PPV ≥ 0.8) for triggering nephrology consultation—provide practical guidance for clinical implementation. Although our ML model demonstrated that early clinical features—such as urine output and SNAP-II score on the first day of life—can predict AKI, the underlying causal mechanisms remain unclear. Current ML methods, including SHAP, primarily reveal associations rather than causation. Zhang et al. [66] proposed the use of marginal structural models with inverse probability weighting to address time-varying confounding in longitudinal observational data. In future neonatal AKI studies, integrating longitudinal data with causal modeling techniques could clarify whether early markers (e.g. fluid balance or SNAP-II) are associated with or directly contribute to AKI development. This enables a shift from risk prediction to mechanism-based prevention and intervention strategies. This study has some limitations. First, laboratory data were limited to the first day after admission because of the lack of longitudinal information. Second, MIMIC-III was obtained from a single U.S. center, which may limit generalizability. Third, external validation is lacking, and future prospective studies with high-quality, multicenter data are needed. Fourth, the missing values were imputed, which may introduce bias. Fifth, ML performance depends on the algorithms and features used; however, there is limited research on optimal configurations. Finally, patient demographics, clinical practices, and data quality in other regions—such as China—may differ, potentially affecting model performance. To address this, we plan to validate and recalibrate the model using local NICU data and encourage multi-center or federated learning studies to enhance robustness. Future work should also assess whether early AKI prediction and intervention improve long-term outcomes, including chronic kidney disease, hypertension, and growth. In conclusion, we developed and internally validated an interpretable XGBoost model capable of accurately predicting AKI within the first seven days of NICU admission in preterm infants. The model demonstrated superior predictive performance compared with conventional scoring systems and other machine learning algorithms. SHAP analysis provided insight into key risk factors, including SNAP-II and first-day urine output, and revealed clinically relevant interactions. Importantly, we established actionable thresholds to guide clinical decision-making, and developed a lightweight Shiny-based tool for bedside risk stratification and early kidney-protective interventions. Figure 11 provides a graphical summary of the study framework and key findings. Graphical Abstract: Interpretable machine learning framework for early prediction of acute kidney injury in preterm infants. Note: The graphical abstract summarizes the study design, machine learning workflow, model performance, clinical risk stratification, and key interpretable findings for predicting acute kidney injury in preterm neonates. Abbreviations: AKI: Acute kidney injury, AUC: Area under the receiver operating characteristic curve, SHAP: SHapley Additive exPlanations. Acknowledgements We gratefully acknowledge the open access provided by the MIMIC-III database. The interpretations and conclusions presented herein are solely those of the authors and do not necessarily reflect the views of the Beth Israel Deaconess Medical Center. Funding Statement The authors confirm that this research was conducted without any external financial support or funding. Disclosure statement No potential conflict of interest was reported by the authors. Data availability The data used in this study were derived from the publicly available MIMIC-III database hosted on PhysioNet. The complete data subset used for model development and evaluation, along with the preprocessing and modeling scripts, have been released at [https://github.com/NewbornAKIPredict/neonatal_AKI_prediction] to enable full reproducibility. References Associated Data Data Availability Statement The data used in this study were derived from the publicly available MIMIC-III database hosted on PhysioNet. The complete data subset used for model development and evaluation, along with the preprocessing and modeling scripts, have been released at [https://github.com/NewbornAKIPredict/neonatal_AKI_prediction] to enable full reproducibility.