Abstract
The energy markets, particularly oil and gas, have been significantly affected by the outbreak of the COVID-19 pandemic in terms of price and availability. In addition to the pandemic, the Russia-Ukraine war has contributed to concerns about the reduction in the oil supply. AI techniques are widely employed for prediction oil prices as an alternative to traditional techniques. In this paper, an AI-based optimization model called adaptive fox-inspired optimization (AFOX) model is presented, then recurrent neural network (RNN) is combined with AFOX to form a hybrid model called recurrent neural network with adaptive fox-inspired (RNN-AFOX) model. The proposed model is used to predict Crude Oil Prices. In the proposed model, AFOX is used to find the best hyper-parameters of the RNN and employed these hyper-parameters to build best RNN structure and use it to forecast the closing price of the oil market. The results show that the RNN-AFOX model achieved a high accuracy prediction with very small error and the coefficient of determination (R-squared) equal to 0.99 outperforming the RNN model in terms of accuracy prediction by about 24%, the FOX model by about 20% and the AFOX model by about 14%. Moreover, RNN-AFOX was evaluated under the impact of the COVID-19 pandemic and the Russia-Ukraine war. The results show the efficiency of RNN-AFOX in forecasting the closing prices of oil with high accuracy. In general, the proposed RNN-AFOX model overcomes other studied models in terms of Mean Absolute Percentage Error, Mean Absolute Error, Mean Square Error, Root Mean Square Error, coefficient of determination (R-squared) and consumption time.
Similar content being viewed by others
References
Abdullah, S.N., & Zeng, X. (2010, July) Machine learning approach for crude oil price prediction with Artificial Neural Networks-Quantitative (ANN-Q) model. Proceedings of the IEEE 2010 International Joint Conference on Neural Networks (IJCNN), pp. 1–8, Barcelona, Spain.
Akl A, El-Henawy I, Salah A (2019) Optimizing deep neural networks hyperparameter positions and values. Journal of Intelligent and Fuzzy Systems 5:6665–6681. https://doi.org/10.3233/JIFS-190033
Alizadeh A, Mafinezhad K (2010) Monthly brent oil price forecasting using artificial neural networks and a crisis index. In: Proceedings of the international conference on electronics and information engineering (ICEIE’2010), Kyoto, pp 465–468
Allam Z, Bibri SE, Sharpe SA (2022) The rising impacts of the COVID-19 pandemic and the Russia–Ukraine War: energy transition, climate justice, global inequality and supply chain disruption. Resources 11:99. https://doi.org/10.3390/resources11110099
Alrahhal H, Alrahhal MS, Jamous R, Jambi K (2020) A symbiotic relationship based leader approach for privacy protection in location based services. Int J Geo Info 9:408–429. https://doi.org/10.3390/ijgi9060408
ALRahhal H, Jamous R (2023) Adaptive fox (AFOX) optimization technique. Artif Intell Rev 2023:1–44
Amin-Naseri MR, Gharacheh EA (2007) A hybrid artificial intelligence approach to monthly forecasting of crude oil price time series. In: Proceedings of the 10th international conference on engineering applications of neural networks (CEANN’2007), Thessaoniki, pp 160–167
Ananthi J, Ranganathan V (2016) Multilayer perceptron weight optimization using Bee swarm algorithm for mobility prediction. IIOAB J 7:47–63
Apaydin H, Feizi H, Sattari MT, Colak MS, Shamshirband S, Chau K (2020) Comparative analysis of recurrent neural network architectures for reservoir inflow forecasting. Water 12:1500–1517. https://doi.org/10.3390/w12051500
Bai Y, Li X, Yu H, Jia S (2021) Crude oil price forecasting incorporating news text. Int J Forecast 38:367–383. https://doi.org/10.1016/j.ijforecast.2021.06.006
Bostanchi H (2018) WTI oil price prediction modeling and forecasting (Master thesis). California State Polytechnic University, Pomona
Busari GA, Lim DH (2021) Crude oil price prediction: a comparison between adaBoost-LSTM and adaBoost-GRU for improving forecasting performance. Comput Chem Eng 155:107513. https://doi.org/10.1016/j.compchemeng.2021.107513
Červený J, Begall S, Koubek P, Nováková P, Burda H (2011) Directional preference may enhance hunting accuracy in foraging foxes. Biol Let 7:355–357. https://doi.org/10.1098/rsbl.2010.1145
Chen Y, He K, Tso GK (2017) Forecasting crude oil prices: a deep learning based model. Proc Comput Sci 122:300–307. https://doi.org/10.1016/j.procs.2017.11.373
Cho K, Merrienboer B, Gulcehre C, Bahdanau D, Bougares F, Schwenk H, Bengio Y (2014) Learning phrase representations using RNN encoder-decoder for statistical machine translation. In: Proceedings of the 2014 conference on empirical methods in natural language processing (EMNLP), Doha, pp 1724–1734
Chowdhury K (2021) 10 Hyperparameters to keep an eye on for your LSTM model—and other tips. https://medium.com/geekculture/10-hyperparameters-to-keep-an-eye-on-for-your-lstm-model-and-other-tips-f0ff5b63fcd4. Accessed 16 Feb 2023
Chung J, Gulcehre C, Cho K, Bengio Y (2014) Empirical evaluation of gated recurrent neural networks on sequence modeling. In: Proceedings of the neural information processing systems workshop on deep learning, Montréal, pp 1–9
COP (2021) Historical data for crude oil prices from 2001 to 2023. COP dataset. Accessed 14 Feb 2023
Deng C, Ma L, Zeng T (2021) Crude oil price forecast based on deep transfer learning: Shanghai crude oil as an example. Sustainability 13:13770. https://doi.org/10.3390/su132413770
Gao S, Lei Y (2017) A new approach for crude oil price prediction based on stream learning. Geosci Front 8:183–187. https://doi.org/10.1016/j.gsf.2016.08.002
Ghanou Y, Bencheikh G (2016) Architecture optimization and training for the multilayer perceptron using ant system. Int J Comput Sci 43:20–26
Guoqiang PZ (2000) Neural networks for classification: a survey. IEEE Trans Syst Man Cybern Part C Appl Rev 30:451–462. https://doi.org/10.1109/5326.897072
Haidar I, Kulkarni S, Pan H (2008) Forecasting model for crude oil prices based on artificial neural networks. In: Proceedings of the international conference on intelligent sensors, sensor networks and information processing (ISSNIP ‘2008), Sydney, pp 103–108
Hatcher WG, Yu W (2018) A survey of deep learning: platforms, applications and emerging research trends. IEEE Access 6:24411–24432. https://doi.org/10.1109/ACCESS.2018.2830661
Hochreiter S, Schmidhuber J (1997) Long short-term memory. Neural Comput 9:1735–1780. https://doi.org/10.1162/neco.1997.9.8.1735
Hu JW, Hu Y, Lin RR (2012) Applying neural networks to prices prediction of crude oil futures. Math Probl Eng 2012:959040. https://doi.org/10.1155/2012/959040
Huang Y, Deng Y (2021) A new crude oil price forecasting model based on variational mode decomposition. Knowl Based Syst 213:106669. https://doi.org/10.1016/j.knosys.2020.106669
Igel I (2012) Hands-on activity: measuring distance with sound waves. Polytechnic Institute of New York University, New York
Investing.com (2023) Historical data for WTI oil prices from 2010 to 2021. https://in.investing.com/commodities/crude-oil-historical-data. Accessed 22 Feb 2023
Islam B, Baharudin Z, MQ R, Nallagownden P (2014) Optimization of neural network architecture using genetic algorithm for load forecasting. In: Proceedings of 2014 5th international conference on intelligent and advanced systems (ICIAS), Kuala, pp 1–6
Jammazi R, Aloui C (2012) Crude oil price forecasting: experimental evidence from wavelet decomposition and neural network modeling. Energy Econ 34:828–841. https://doi.org/10.1016/j.eneco.2011.07.018
Jamous R, Alrahhal H, El-Darieby M (2021a) A new ANN-particle swarm optimization with center of gravity (ANN-PSOCoG) prediction model for the stock market under the effect of covid-19. Sci Program 2021:1–17. https://doi.org/10.1155/2021/6656150
Jamous R, Alrahhal H, El-Darieby M (2021b) Neural network architecture selection using particle swarm optimization technique. Appl Artif Intell 35:1219–1236. https://doi.org/10.1080/08839514.2021.1972251
Jarrett K, Kavukcuoglu K, Ranzato MA, LeCun Y (2009) What is the best multi-stage architecture for object recognition? In: Proceedings of the 2009 IEEE 12th international conference on computer vision, Kyoto, pp 2146–2153
Karasu S, Altan A, Bekiros S, Ahmad W (2020) A new forecasting model with wrapper-based feature selection approach using multi-objective optimization technique for chaotic crude oil time series. Energy 212:118750. https://doi.org/10.1016/j.energy.2020.118750
Kaveh A, Mahjoubi S (2018) Lion pride optimization algorithm: a meta-heuristic method for global optimization problems. Sci Iran 25:3113–3132. https://doi.org/10.24200/SCI.2018.20833
Ke S, Pan Z, He T, Liang Y, Zhang J, Zheng Y (2023) AutoSTG+: an automatic framework to discover the optimal network for spatio-temporal graph prediction. Artif Intell 318:103899. https://doi.org/10.1016/j.artint.2023.103899
Kulkarni S, Haidar I (2009) Forecasting model for crude oil price using artificial neural networks and commodity futures prices. Int J Comput Sci Info Secur 2:81–88
Kurnia R (2022) Tuning the hyperparameters and layers of neural network deep learning. https://www.analyticsvidhya.com/blog/2021/05/tuning-the-hyperparameters-and-layers-of-neural-network-deep-learning/. Accessed 16 Feb 2023
Liu B, Li Y, Li G, Liu A (2019) A spectral feature based convolutional neural network for classification of sea surface oil spill. ISPRS Int J Geo-Inf 8:160. https://doi.org/10.3390/ijgi8040160
Lv Z, Xu J, Zheng K, Yin H, Zhao P, Zhou X (2018) Lc-rnn: a deep learning model for traffic speed prediction. In: Proceedings of the 27 international joint conference on artificial intelligence (IJCAI-18), Stockholm, pp 3470–3476
Mahdiani MR, Khamehchi E (2016) A modified neural network model for predicting the crude oil price. Intellect Econ 10:71–77. https://doi.org/10.1016/j.intele.2017.02.001
Mirjalili S, Lewis A (2016) The whale optimization algorithm. Adv Eng Softw 95:51–67. https://doi.org/10.1016/j.advengsoft.2016.01.008
Mohammed H, Rashid T (2022) FOX: a FOX-inspired optimization algorithm. Appl Intell 53:1030–1050. https://doi.org/10.1007/s10489-022-03533-0
Norouzi N, Fani M (2020) The impacts of the novel corona virus on the oil and electricity demand in Iran and China. J Energy Manage Technol 4:36–48. https://doi.org/10.22109/JEMT.2020.222593.1232
Orojo O, Tepper J, McGinnity TM, Mahmud M (2019) A multi-recurrent network for crude oil price prediction. In: Proceedings of the 2019 IEEE symposium series on computational intelligence (SSCI), Xiamen, pp 2940–2945
Panchal G, Ganatra A, Kosta Y (2011) Behaviour analysis of multilayer perceptrons with multiple hidden neurons and hidden layers. Int J Comput Theory Eng 3:332–337. https://doi.org/10.7763/IJCTE.2011.V3.328
Pang Y, Xu W, Yu L, Ma J, Lai KK, Wang S, Xu S (2011) Forecasting the crude oil spot price by wavelet neural networks using OECD petroleum inventory levels. New Math Nat Comput 7:281–297. https://doi.org/10.1142/S1793005711001937
Rubaszek M (2021) Forecasting crude oil prices with DSGE models. Int J Forecast 37:531–546. https://doi.org/10.1016/j.ijforecast.2020.07.004
Sohrabi P, Dehghani H, Rafie R (2022) Forecasting of WTI crude oil using combined ANN-Whale optimization algorithm. Energy Sources Part B 17:2083728. https://doi.org/10.1016/j.fuel.2021.122523
STEO (2023) Short-term energy outlook, report. STEO. Accessed 14 Feb 2023
Thomas AJ, Petridis M, Walters SD, Gheytassi SM, Morgan RE (2015) On predicting the optimal number of hidden nodes. In: Proceedings of the 2015 international conference on computational science and computational intelligence, Las Vegas, pp. 565–570
Vic L, Jovanovic D, Bacanin N, Jovancai SA, Antonijevic M, Magd H, Thirumalaisamy R, Zivkovic M (2022) Multi-step crude oil price prediction based on LSTM approach tuned by Salp Swarm algorithm with disputation operator. Sustainability 14:14616. https://doi.org/10.3390/su142114616
Wang S, Yu L, Lai KK (2004) A novel hybrid AI system framework for crude oil price forecasting. In: Shi Y, Xu W, Chen Z (eds) Data mining and knowledge management. Springer, Berlin, pp 233–242
Wang S, Ma C, Xu Y, Wang J, Wu W (2022) A hyperparameter optimization algorithm for the LSTM temperature prediction model in data center. Sci Program. https://doi.org/10.1155/2022/6519909
Wang J, Qiang X, Ren Z, Wang H, Wang Y, Wang S (2023) Time-series well performance prediction based on convolutional and long short-term memory neural network model. Energies 16:499–515. https://doi.org/10.3390/en16010499
Wu J, Miu F, Li T (2020) Daily crude oil price forecasting based on improved CEEMDAN, SCA and RVFL: a case study in WTI oil market. Energies 13:1–20. https://doi.org/10.3390/en13071852
Wu B, Wang L, Lv SX, Zeng YR (2021a) Effective crude oil price forecasting using new text-based and big-data-driven model. Measurement 168:108468. https://doi.org/10.1016/j.measurement.2020.108468
Wu B, Wang L, Wang S, Zeng YR (2021b) Forecasting the US oil markets based on social media information during the COVID-19 pandemic. Energy 226:120403. https://doi.org/10.1016/j.energy.2021.120403
Xie W, Yu L, Xu S, Wang S (2006) A new method for crude oil price forecasting based on support vector machines. In: Alexandrov VN, van Albada GD, Sloot PMA, Dongarra J (eds) Computational science. Springer, Berlin, pp 444–451
Xu Z, Zhang J, Wang J (2020) Prediction research of financial time series based on deep learning. Soft Comput 24:8295–8312. https://doi.org/10.1007/s00500-020-04788-w
Yan L, Zhu Y, Wang H (2021) Selection of machine learning models for oil price forecasting: based on the dual attributes of oil. Discret Dyn Nat Soc. https://doi.org/10.1155/2021/1566093
Yin T, Wang Y (2022) Predicting the price of WTI crude oil futures using artificial intelligence model with chaos. Fuel 316:122523. https://doi.org/10.1016/j.fuel.2021.122523
Yin L, Yang Q (2016) Predicting the oil prices: do technical indicators help? Energy Econ 56:338–350. https://doi.org/10.1016/j.eneco.2016.03.017
Zajmi L, Falah Y, Ahmed H, Adam J (2018) Concepts, methods and performances of particle swarm optimization, backpropagation and neural networks. Appl Comput Intell Soft Comput. https://doi.org/10.1155/2018/9547212
Funding
The authors did not receive support from any organization for the submitted work.
Author information
Authors and Affiliations
Contributions
Conceptualization, HALR and RJ; Methodology, HALR and RJ; Software, HALR and RJ; Formal Analysis, HALR and RJ; Data Curation, HALR and RJ; Writing-Original Draft Preparation, HALR and RJ, Writing—review and editing, HALR and RJ. All authors have read and agreed to the published version of the manuscript.
Corresponding author
Ethics declarations
Conflict of interest
The authors declare that they have no conflict of interest regarding the publication of this article.
Ethical approval
This article does not contain any studies with human participants or animals performed by any of the authors.
Additional information
Publisher's Note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Rights and permissions
Springer Nature or its licensor (e.g. a society or other partner) holds exclusive rights to this article under a publishing agreement with the author(s) or other rightsholder(s); author self-archiving of the accepted manuscript version of this article is solely governed by the terms of such publishing agreement and applicable law.
About this article
Cite this article
ALRahhal, H., Jamous, R. RNN-AFOX: adaptive FOX-inspired-based technique for automated tuning of recurrent neural network hyper-parameters. Artif Intell Rev 56 (Suppl 2), 1981–2011 (2023). https://doi.org/10.1007/s10462-023-10568-3
Published:
Issue Date:
DOI: https://doi.org/10.1007/s10462-023-10568-3