Machine learning ensemble models for hourly temperature prediction in arid urban environments: A comparative study with applications to climate-responsive planning
Accurate hourly temperature prediction is essential for energy demand planning, public health management, and climate adaptation strategies in rapidly urbanizing arid regions. This study develops and evaluates a comprehensive framework for predicting hourly air temperature in Riyadh, Saudi Arabia, using 23 years of meteorological data (2001–2023). Six machine learning and deep learning models, namely Long Short-Term Memory (LSTM), Convolutional Neural Networks (CNN), Artificial Neural Networks (ANN), Recurrent Neural Networks (RNN), Support Vector Machines (SVM), and Random Forest (RF) were applied for hourly temperature prediction. We compared their performance using a temporary independent framework. The dataset was partitioned chronologically into training, validation, and independent testing periods, and preprocessing parameters were estimated exclusively from the training data to prevent information leakage. Lagged-correlation and multivariate analyses were also conducted to examine the strength and temporal structure of associations between meteorological variables and hourly air temperature. Among the evaluated models, LSTM exhibited the best independent-test performance (R 2 = 0.99981, RMSE = 0.1371°C, MAE = 0.1092°C), followed by RNN (R 2 = 0.99944, RMSE = 0.2320°C) and RF (R 2 = 0.9992, RMSE = 0.2739°C). ANN also showed strong predictive ability, whereas CNN and SVM yielded comparatively larger errors. The lagged-correlation analysis further revealed that the strength and timing of meteorological associations with air temperature varied across predictors, indicating a clear temporal structure in hourly temperature dynamics. The framework provides highly accurate hourly temperature estimates and demonstrates the value of combining temporal climate analysis with machine-learning and deep-learning methods for cooling-demand assessment, building-energy applications, and climate-responsive urban planning in arid cities.
Authors
- Mohammed J. Alshayeb (ORCID: https://orcid.org/0000-0002-7760-860X)
- Saleh Hamed Alsulamy (ORCID: https://orcid.org/0000-0001-6991-1855)
- Abdulla ‐ Al Kafy (ORCID: https://orcid.org/0000-0002-7544-5165)
- Ahmed Ali A. Shohan (ORCID: https://orcid.org/0000-0001-6339-2329)
Institutions
- King Khalid University (SA)
- The University of Texas at Austin (US)
Publication Details
- Journal
- PLoS ONE
- Published
- 2026-11-30
- DOI
- https://doi.org/10.1371/journal.pone.0363669
- Primary Topic
- Urban Heat Island Mitigation
- Type
- article
- Field-Weighted Citation Impact
- 0.00