Improved SHAP-guided ensemble framework for precise traffic flow prediction
Abstract
Accurate and reliable traffic flow prediction constitutes a critical component of intelligent transportation systems (ITS), enabling improved traffic management and environmental sustainability. Ensemble methodologies, which combine the strengths of multiple predictive models, have emerged as powerful approaches in complex forecasting tasks. This paper introduces an advanced SHAP-driven boosting framework that incorporates SHapley Additive exPlanations (SHAP) analysis as an iterative guide within the CatBoost and XGBoost models development process and the grid search optimizer to improve the accuracy and interpretability of traffic flow prediction. The SHAP analysis is introduced to identify the most influential lag features, providing insights into the key patterns driving traffic dynamics. Meanwhile, grid search is incorporated to fine-tune the paradigm hyperparameters, ensuring optimal performance. The proposed framework is systematically evaluated using multi-source datasets from Utah highways, and benchmarked against traditional models (decision tree, Random Forest, SVR, Linear/Lasso Regression) as well as deep learning models (CNN, LSTM, GRU, BiLSTM, CNN-LSTM). Experimental results confirm that the SHAP-driven boosting framework consistently outperforms all comparative models, achieving the highest R 2 scores and the lowest error metrics ( R M S E , M A E , and M A P E ) across various data sources and sampling intervals. These findings were confirmed by Diebold–Mariano and Wilcoxon signed-rank tests ( p < 0.05 ). The framework consistently yields sharper, well-calibrated prediction intervals, establishing it as a highly accurate, statistically robust, and interpretable solution for traffic flow forecasting.