Work

Predicting length of hospital stay in community-acquired pneumonia using clinical and treatment factors: a retrospective study with restricted cubic spline and piecewise regression analysis

Year: 2026
Type: article
Study design: Observational Study
Abstract: Background Community-acquired pneumonia (CAP) remains a leading cause of hospitalization worldwide. Accurate prediction of length of stay (LOS) is crucial for optimizing hospital bed turnover, improving clinical resource allocation, and facilitating the development of individualized discharge plans, thereby reducing the strain on healthcare systems. Methods We retrospectively analyzed 423 adults hospitalized with CAP from January 2022 to December 2023. Clinical characteristics, laboratory data, comorbidities, and treatment variables were extracted from electronic health records. Univariate and multivariable linear regression models were initially employed to identify independent predictors of LOS. The predictive performance of the final multivariable model was assessed using R 2 , adjusted R 2 , Akaike Information Criterion, and 10-fold cross-validation. To further explain the complex relationship between specific treatment factors and LOS, restricted cubic splines and piecewise regression were utilized, specifically to evaluate non-linear associations and identify clinical inflection points. Results The final model showed strong performance (R 2 = 0.864; adjusted R 2 = 0.862). Independent predictors of prolonged LOS included respiratory failure, pressure ulcers, elevated blood urea nitrogen, antibiotic modification during hospitalization, traditional Chinese medicine use, and antibiotic duration. Restricted cubic spline analysis demonstrated a significant non-linear relationship between antibiotic duration and LOS ( P < 0.05). Piecewise regression identified an inflection point at 7.398 days, after which LOS increased more rapidly. Conclusions Multiple clinical and treatment-related factors were associated with LOS in CAP. Antibiotic duration showed a pronounced non-linear pattern, with treatment beyond 1 week linked to markedly longer hospitalization. These findings may help identify patients at risk of prolonged LOS and support more efficient clinical decision-making.
Language: English
Subfield: Epidemiology
Field: Medicine
Open Access status: gold
Estimated APC paid: $3,801
OpenAlex ID: W7155163029
FWCI:
Cites: 20
Cited by:
Related to: