Children with Mycoplasma pneumoniae pneumonia sometimes develop plastic bronchitis, a rare complication in which branching, fibrin-rich casts form inside the airways and can partially or completely block them. Because the diagnosis is confirmed only when such a cast is pulled out during flexible bronchoscopy, and because the condition can progress quickly toward hypoxemia, respiratory failure, or even death, clinicians have long wanted a way to flag high-risk children earlier. A new single-center retrospective study from the Affiliated Hospital of Yan’an University in Shaanxi, China, reports that machine learning models built from routine admission data can estimate that risk with moderate-to-good discrimination, and the authors have released two web-based calculators built on their best-performing algorithms.
The study, published in Frontiers in Pediatrics on 30 October 2026, enrolled 702 hospitalized children with Mycoplasma pneumoniae pneumonia who underwent fiberoptic bronchoscopy for clinical indications between January 2023 and January 2026. Of these, 477 did not have plastic bronchitis and 225 did, the latter defined by retrieval of a cast specimen with a bronchial branching shape during bronchoscopy. The cohort was drawn from 750 consecutively screened children after 48 were excluded, and children with underlying conditions such as tuberculosis, asthma, congenital heart disease, neuromuscular disorders, immunodeficiencies, or hereditary and metabolic diseases were not eligible. The authors emphasize that because the population was restricted to children already selected for bronchoscopy, the observed plastic bronchitis proportion should not be read as the overall incidence among unselected children with the pneumonia.
The researchers collected clinical characteristics, laboratory findings, and imaging data, defining hospital admission as the prediction time origin. All predictor variables came from admission or from assessments, blood tests, and imaging performed within 24 hours after admission, and everything was collected before bronchoscopy and before plastic bronchitis was confirmed. Fever duration and peak temperature were taken from the admission history rather than from later clinical-course data. Every child underwent non-contrast chest computed tomography within 24 hours of admission, with images reviewed independently by two experienced radiologists and disagreements settled by a third senior radiologist. Missing values were handled with a random forest-based iterative imputation approach fitted only on the training set to avoid data leakage, and variables missing more than 20 percent of values were excluded.
Feature selection used a two-stage Lasso–Boruta procedure. L1-regularized logistic regression first reduced the original feature set to 22 candidates, and repeated Boruta analysis, run for 10 independent iterations against randomly generated shadow features, retained nine variables confirmed in at least five runs: fever duration, peak temperature, white blood cell count, C-reactive protein, albumin, lactate dehydrogenase, fibrinogen degradation products, D-dimer, and pulmonary consolidation. Before selection, the group comparisons had already shown clear differences between the two cohorts. Children who developed plastic bronchitis had longer fever duration, higher peak fever, and higher rates of wheezing, tachypnea, abdominal pain, and vomiting. Their laboratory panels showed elevated white blood cell counts, neutrophil percentages, C-reactive protein, lactate dehydrogenase, fibrinogen, fibrinogen degradation products, and D-dimer, along with lower lymphocyte percentages, red blood cell counts, hemoglobin, and albumin. On imaging, pulmonary consolidation was present in 88.44 percent of the plastic bronchitis group versus 29.14 percent of the non-PB group, atelectasis in 16.00 percent versus 1.47 percent, and pleural effusion in 31.56 percent versus 5.24 percent.
The dataset was split 7:3 into training and test cohorts of 491 and 211 children using stratified random sampling, and eight machine learning models were trained: CatBoost, XGBoost, LightGBM, random forest, logistic regression, support vector machine, Gaussian naive Bayes, and K-nearest neighbors. Hyperparameters were tuned with five-fold stratified cross-validation using grid or random search, with the F1 score as the optimization criterion. In the training set, KNN, XGBoost, and LightGBM posted perfect scores of 1.000 across accuracy, precision, recall, F1, and ROC-AUC, a pattern the authors treated as a warning sign rather than a triumph. In the independent test set, performance dropped for every model: accuracy ranged from 0.807 to 0.853, F1 from 0.667 to 0.762, and ROC-AUC from 0.854 to 0.881. Random forest achieved an accuracy of 0.853, precision of 0.804, recall of 0.721, F1 of 0.759, and the highest test ROC-AUC of 0.881, while CatBoost matched the accuracy at 0.853 with precision of 0.793, recall of 0.736, F1 of 0.762, and ROC-AUC of 0.871.
The overfitting analysis quantified how much each model’s test performance fell below its training performance. The largest F1 gaps appeared for KNN at 0.293, followed by LightGBM at 0.250, XGBoost at 0.246, and CatBoost at 0.228, whereas random forest’s F1 gap was 0.077. For ROC-AUC, the training-test differences were 0.145 for KNN, 0.129 for CatBoost, 0.122 for XGBoost, 0.120 for LightGBM, and 0.075 for random forest. Learning curves showed that validation performance stabilized as training sample size grew, with no model showing a continuous decline, though the size of the training-validation gap varied by algorithm. Bootstrap comparisons using CatBoost as the reference found that after Bonferroni correction, none of the ROC-AUC differences between CatBoost and the other seven models remained statistically significant, and only the F1 difference between CatBoost and Gaussian naive Bayes was significant at P = 0.042. The authors therefore declined to crown a single winner on the basis of one metric or one test set.
Probabilistic performance added another layer of nuance. PR-AUC values across the eight models ranged from 0.719 to 0.792, with LightGBM highest at 0.792, followed by XGBoost at 0.778 and random forest at 0.769. Brier scores were 0.122 for random forest and 0.123 for CatBoost, and calibration characteristics differed: random forest posted a calibration slope of 1.077 and intercept of 0.089, while CatBoost’s slope was 0.664 with an intercept of −0.086. The authors note that calibration curves fluctuated partly because the test set contained only 211 patients, leaving few cases in some predicted-probability ranges and making observed event-rate estimates unstable. Decision curve analysis showed that most models delivered higher net benefit than treat-all and treat-none strategies over certain threshold ranges, though the curves overlapped and intersected across a broad span of thresholds.
Temporal validation tested whether the models held up on later patients. Children admitted between January 2023 and December 2024, numbering 622, formed the development cohort, while the 80 children admitted between January 2025 and January 2026 formed the temporal test set. Performance in that later window was stronger across the board: accuracy ranged from 0.825 to 0.925, F1 from 0.759 to 0.900, ROC-AUC from 0.922 to 0.970, PR-AUC from 0.873 to 0.956, and Brier scores from 0.073 to 0.134. Random forest achieved the highest accuracy, 0.925, and the highest F1, 0.900, while CatBoost posted the top ROC-AUC of 0.970, PR-AUC of 0.956, and a Brier score of 0.076. Bootstrap optimism correction within the 2023–2024 development set trimmed random forest’s corrected AUC, F1, and accuracy to 0.916, 0.763, and 0.862, compared with 0.969, 0.883, and 0.928 for CatBoost. On the strength of these complementary profiles, the team retained both models as candidates for interpretation and tool development. A sensitivity analysis that removed fever duration and peak temperature left performance essentially unchanged, with accuracy between 0.787 and 0.858 and ROC-AUC between 0.852 and 0.883, supporting the robustness of the primary findings.
SHAP analysis offered a window into what the retained models were actually learning. In the random forest model, lactate dehydrogenase and pulmonary consolidation carried the highest mean absolute SHAP values, followed by D-dimer, fibrinogen degradation products, and C-reactive protein; in CatBoost, pulmonary consolidation and lactate dehydrogenase led, followed by fibrinogen degradation products, C-reactive protein, and D-dimer. Beeswarm plots showed that the presence of pulmonary consolidation was predominantly associated with positive SHAP values, pushing predictions toward higher plastic bronchitis probability, while higher levels of lactate dehydrogenase, fibrinogen degradation products, C-reactive protein, and D-dimer also generally contributed positively. Fever duration, peak temperature, and white blood cell count contributed less overall but showed individual-level heterogeneity, and albumin had a limited contribution, behaving protectively when lower in the plastic bronchitis group. The authors connect these signals to biology: lactate dehydrogenase reflects pulmonary inflammatory activation and tissue injury, fibrinogen degradation products and D-dimer mark coagulation–fibrinolysis activation that can promote microthrombi and fibrin-rich cast material, and C-reactive protein and white blood cells index systemic inflammation that can injure airway epithelium and impair mucus clearance.
The practical output is a single web application hosting two model-specific calculators, one random forest and one CatBoost, both built on the same nine predictors and deployable on Streamlit Community Cloud. Users enter patient-level clinical, laboratory, and imaging information available within 24 hours of admission, and each calculator returns an individualized predicted probability of plastic bronchitis, a model-specific decision threshold, a risk classification, and SHAP-based visualizations of each predictor’s contribution. The authors position the tools as research-oriented aids for risk assessment and model interpretation rather than replacements for clinical judgment. The limitations they list are substantial: the study was single-center and retrospective, restricted to bronchoscopied children, with no formal severity stratification; laboratory values came from a single cross-sectional measurement that could not capture dynamic biomarker changes; the exact timing of bronchoscopy was not systematically recorded, so any time benefit of earlier risk identification could not be quantified; and no independent external validation was performed, with race and ethnicity not systematically recorded. Cytokine profiles and ferritin were not included. The authors conclude that multicenter prospective studies are needed to validate the models externally and to evaluate the clinical applicability of the web-based calculator before it can be trusted in broader, unselected populations.
Subject of Research: Machine learning prediction of plastic bronchitis risk in children hospitalized with Mycoplasma pneumoniae pneumonia
Article Title: Machine learning models for predicting plastic bronchitis in hospitalized children with Mycoplasma pneumoniae pneumonia undergoing clinically indicated bronchoscopy: a single-center retrospective study
Article References: Yu, S., Li, Y., Liu, Q., Xue, Z., Gao, Y., Yang, Y., & Li, Y. (2026). Machine learning models for predicting plastic bronchitis in hospitalized children with Mycoplasma pneumoniae pneumonia undergoing clinically indicated bronchoscopy: a single-center retrospective study. Frontiers in Pediatrics, 14, 1983032. https://doi.org/10.3389/fped.2026.1983032
Image Credits: AI Generated
DOI: 10.3389/fped.2026.1983032
Keywords: Mycoplasma pneumoniae pneumonia, plastic bronchitis, machine learning, random forest, CatBoost, SHAP, risk prediction model, pediatric pulmonology, bronchoscopy, LDH, D-dimer, temporal validation
News Source: Teresa Odom. (October 30, 2026). Machine Learning Flags Airway Cast Risk in Children With Mycoplasma Pneumonia. Scienmag.



