Application of Artificial Intelligence Algorithms to Improve the Accuracy of Agricultural Weather Predictions
Keywords:
artificial intelligence, LSTM, Random Forest, sustainable agriculture, weather predictionAbstract
Climate change, marked by increasing uncertainty in weather patterns, poses significant challenges to agricultural productivity in Indonesia. Accurate weather forecasting is therefore essential to support sustainable agrarian efficiency, parti-cularly in determining planting schedules, irrigation management, and mitigating crop failure risk. This study aims to apply artificial intelligence (AI) algorithms to improve weather prediction accuracy by comparing the performance of Long Short-Term Memory (LSTM), Random Forest (RF), and conventional methods, including ARIMA and Least Squares Method (LSM). The dataset used consists of historical meteorological parameters, including temperature, humidity, rainfall, and wind speed. The research process involved data collection, preprocessing, model development, and evaluation using RMSE, MAE, and R². The results reveal that LSTM outperforms the other models with an R² of 0.92, RMSE of 0.15, and MAE of 0.11, while RF achieved an R² of 0.85. In contrast, ARIMA and LSM showed lower performance with R² values below 0.80, highlighting the limitations of conventional approaches in capturing non-linear weather patterns. These findings confirm that the application of AI algorithms, particularly LSTM, provides more accurate weather forecasting, which directly contributes to sustainable agricultural practices by improving efficiency and resilience to climate variability.
References
Abiodun, O. I., Jantan, A., Omolara, A. E., Dada, K. V., Mohamed, N. A. E., & Arshad, H. (2018). State-of-the-art in artificial neural network applications: A survey. Heliyon, 4(11), e00938.
Chai, T., & Draxler, R. R. (2014). Root mean square error (RMSE) or mean absolute error (MAE)?–Arguments against avoiding RMSE in the literature. Geoscientific Model Development, 7(3), 1247–1250.
Cipriano, D., Cefalì, A. M., & Allegrini, M. (2021). Experimenting with odour proficiency tests implementation using synthetic bench loops. Atmosphere, 12(761), 1–12.
Devi, T., Deepa, N., Gayathri, N., & Kumar, S. R. (2024). AI-based weather forecasting system for smart agriculture system using a recurrent neural networks (RNN) algorithm. In A. Kumar, P. S. Rathore, A. K. Dubey, A. L. Srivastav, T. A. Kumar, & V. Dutt (Eds.), Sustainable management of electronic waste (pp. 97-112). Wiley.
Garofalo, S. P., Ardito, F., Sanitate, N., De Carolis, G., Ruggieri, S., Giannico, V., ... & Ferrara, R. M. (2025). Robustness of actual evapotranspiration predicted by random forest model integrating remote sensing and meteorological information: Case of watermelon (Citrullus lanatus, (Thunb.) Matsum. & Nakai, 1916). Water, 17(3), 323.
Kothiyal, S., Goel, S., Singh, R. K., Chilwal, A., & Ranjan, R. (2025). SARIMA-based time series analysis of rainfall and temperature for the Tarai region of Uttarakhand. Journal of Agrometeorology, 22(1), 73–76.
Nurhanif, Away, Y., & Surbakti, M. S. (2021). Performance analysis of database synchronization on DBMS MySQL and Oracle by using event-driven and time-driven data for weather monitoring. Journal of Aceh Physics Society, 10(4), 107–112.
Peeriga, R., Rinku, D. R., Bhaskar, J. U., Nagalingam, R., Aldosari, F. M., Albarakati, H. M., ... & Jaffar, A. Y. (2024). Real-time rain prediction in agriculture using AI and IOT: A bi-directional LSTM approach. Engineering, Technology & Applied Science Research, 14(4), 15805-15812.
Rangelov, D., Boerger, M., Tcholtchev, N., Lämmel, P., & Hauswirth, M. (2023). Design and development of a short-term photovoltaic power output forecasting method based on random forest, deep neural network and LSTM using readily available weather features. IEEE Access, 11, 41578-41595.
Ray, S., Lama, A., Mishra, P., Biswas, T., Das, S. S., & Gurung, B. (2023). An ARIMA-LSTM model for predicting volatile agricultural price series with random forest technique. Applied Soft Computing, 149, 110939.
Roopmathi, P., Chockalingam, J., & Khadir, A. S. A. (2025). A big data virtualization role in agriculture and cloud computing-base smart agriculture. Educational Administration: Theory and Practice, 30(5), 4565–4573.
Salas-Martínez, F., Márquez-Grajales, A., Valdés-Rodríguez, O. A., Palacios-Wassenaar, O. M., & Pérez-Castro, N. (2024). Prediction of agricultural drought behavior using the Long Short-Term Memory Network (LSTM) in the central area of the Gulf of Mexico. Theoretical and Applied Climatology, 155(8), 7887-7907.
Wolfert, S., Ge, L., Verdouw, C., & Bogaardt, M. J. (2017). Big Data in Smart Farming – A review. Agricultural Systems, 153, 69–80.
Downloads
Published
Issue
Section
License
Copyright (c) 2026 Geubrina Maghfirah, Nurhanif, Yeni Yanti, Muliadi (Author)

This work is licensed under a Creative Commons Attribution 4.0 International License.






