Introduction
Severe pneumonia remains a leading cause of mortality among children under five in Uganda. Proactive public health interventions are hindered by the lack of reliable forecasting tools. This study aimed to develop and deploy a predictive model for weekly severe pneumonia cases in Kampala by integrating meteorological data and influenza-like illness (ILI) indicators.
Methods
A time-series study was conducted using 315 weeks of data (2019-2024) from Uganda’s District Health Information Software 2 (DHIS2) and the Uganda National Meteorological Authority. We developed and compared three models: Auto-Regressive Integrated Moving Average with Exogenous variables (ARIMAX), Random Forest, and Extreme Gradient Boosting (XGBoost). Models were trained and validated using time-series cross-validation. The best-performing model was deployed as a web-based application using the Flask framework. Model performance was evaluated using Root Mean Squared Error (RMSE).
Results
The XGBoost model demonstrated the highest predictive accuracy with an RMSE of 85.2, followed by Random Forest (RMSE=92.7) and ARIMAX (RMSE=105.4). An ensemble of XGBoost and ARIMAX further improved performance (RMSE=80.3). Temperature was a statistically significant predictor in the ARIMAX model (p=0.010). The best-performing model was successfully deployed as an accessible web application that allows healthcare workers to input variables like temperature, rainfall, and ILI cases to receive real-time weekly forecasts.
Conclusion
Machine learning models, particularly XGBoost, outperformed traditional statistical models in forecasting pediatric severe pneumonia cases in a low-resource setting. The deployment of a user-friendly, web-based tool enables the practical application of these forecasts for early warning, improving resource allocation, and strengthening public health preparedness in Kampala.