journal article·2025-06-12Open access

IGWO-MALSTM: An Improved Grey Wolf-Optimized Hybrid LSTM with Multi-Head Attention for Financial Time Series Forecasting

Mingfu Zhu, Haoran Qi, Panke Qin

Applied Sciences· Volume 15· Issue 12

Abstract

In the domain of financial markets, deep learning techniques have emerged as a significant tool for the development of investment strategies. The present study investigates the potential of time series forecasting (TSF) in financial application scenarios, aiming to predict future spreads and inform investment decisions more effectively. However, the inherent nonlinearity and high volatility of financial time series pose significant challenges for accurate forecasting. To address these issues, this paper proposes the IGWO-MALSTM model, a hybrid framework that integrates Improved Grey Wolf Optimization (IGWO) for hyperparameter tuning and a multi-head attention (MA) mechanism to enhance long-term sequence modeling within the long short-term memory (LSTM) architecture. The IGWO algorithm improves population diversity during initialization using the Mersenne Twister, thereby enhancing the convergence speed and search capability of the optimizer. Simultaneously, the MA mechanism mitigates gradient vanishing and explosion problems, enabling the model to better capture long-range dependencies in financial sequences. Experimental results on real futures market data demonstrate that the proposed model reduces Mean Square Error (MSE) by up to 61.45% and Mean Absolute Error (MAE) by 44.53%, and increases the R2 score by 0.83% compared to existing benchmark models. These findings confirm that IGWO-MALSTM offers improved predictive accuracy and stability for financial time series forecasting tasks.
Source: crossref · Quality: baseline

Research context

OpenAlex topics: Stock Market Forecasting Methods · Energy Load and Power Forecasting · Forecasting Techniques and Applications

SciVX discovery tags are terminology-based. OpenAlex topics are source-provided classifications.

Affiliations

School of Computer Science and Technology, Henan Polytechnic University, Jiaozuo 454150, China

Hebi National Optoelectronic Technology Co., Ltd., Hebi 458000, China

Funding

Key Research Project of Henan Province · “Double first-class” discipline creation Project of Surveying and Mapping Science and Technology

References (59)

Show source-provided references
1. Efficient capital markets10.2307/2325486 ↗
2. Stock market volatility: Identifying major drivers and the nature of their impact10.1016/j.jbankfin.2015.04.003 ↗
3. International economic policy uncertainty and stock market returns of Bangladesh: Evidence from linear and nonlinear model10.3934/QFE.2020011 ↗
4. Support-vector networks10.1007/BF00994018 ↗
6. Nearest neighbor pattern classification10.1109/TIT.1967.1053964 ↗
7. Tsay, R.S. (2005). Analysis of Financial Time Series, John Wiley and Sons.10.1002/0471746193 ↗
8. A multi-scale time-series dataset with benchmark for machine learning in decarbonized energy grids10.1038/s41597-022-01455-7 ↗
9. Stasiak, M.D., Staszak, Ż., Siwek, J., and Wojcieszak, D. (2025). Application of State Models in a Binary–Temporal Representation for the Prediction and Modelling of Crude Oil Prices. Energies, 18.10.3390/en18030691 ↗
10. Long short-term memory10.1162/neco.1997.9.8.1735 ↗
11. Deep learning10.1038/nature14539 ↗
12. Graves, A., and Graves, A. (2012). Supervised Sequence Labelling, Springer.10.1007/978-3-642-24797-2_2 ↗
13. Deep learning with long short-term memory networks for financial market predictions10.1016/j.ejor.2017.11.054 ↗
14. Financial time series forecasting with deep learning: A systematic literature review: 2005–201910.1016/j.asoc.2020.106181 ↗
15. Chen, K., Zhou, Y., and Dai, F. (November, January 29). A LSTM-based method for stock returns prediction: A case study of China stock market. Proceedings of the 2015 IEEE International Conference on Big Data (Big Data), Santa Clara, CA, USA.10.1109/BigData.2015.7364089 ↗
16. Learning long-term dependencies with gradient descent is difficult10.1109/72.279181 ↗
17. Evolving CNN-LSTM models for time series prediction using enhanced grey wolf optimizer10.1109/ACCESS.2020.3021527 ↗
18. Lipton, Z.C., Berkowitz, J., and Elkan, C. (2015). A critical review of recurrent neural networks for sequence learning. arXiv.
19. Learning to forget: Continual prediction with LSTM10.1162/089976600300015015 ↗
20. Goodfellow, I., Bengio, Y., and Courville, A. (2016). Deep Learning, MIT Press.
21. A comprehensive analysis of nature-inspired meta-heuristic techniques for feature selection problem10.1007/s11831-020-09412-6 ↗
22. Vaswani, A., Shazeer, N., Parmar, N., Uszkoreit, J., Jones, L., Gomez, A.N., Kaiser, Ł., and Polosukhin, I. (2017). Attention is all you need. Advances in Neural Information Processing Systems, Curran Associates, Inc.
23. Hamilton, J.D. (2020). Time Series Analysis, Princeton University Press.10.2307/j.ctv14jx6sm ↗
24. Macroeconomics and reality
25. Pesaran, M.H., and Shin, Y. (1995). An Autoregressive Distributed Lag Modelling Approach to Cointegration Analysis, Department of Applied Economics, University of Cambridge.
26. Autoregressive conditional heteroscedasticity with estimates of the variance of United Kingdom inflation
27. Generalized autoregressive conditional heteroskedasticity10.1016/0304-4076(86)90063-1 ↗
28. Predicting volatility: Getting the most out of return data sampled at different frequencies10.1016/j.jeconom.2005.01.004 ↗
29. Time series forecasting using a hybrid ARIMA and neural network model10.1016/S0925-2312(01)00702-0 ↗
30. A hybrid model based on neural networks for biomedical relation extraction10.1016/j.jbi.2018.03.011 ↗
31. Predicting stock and stock price index movement using trend deterministic data preparation and machine learning techniques10.1016/j.eswa.2014.07.040 ↗
32. Surveying stock market forecasting techniques—Part II: Soft computing methods10.1016/j.eswa.2008.07.006 ↗
33. Bao, W., Yue, J., and Rao, Y. (2017). A deep learning framework for financial time series using stacked autoencoders and long-short term memory. PLoS ONE, 12.10.1371/journal.pone.0180944 ↗
34. Forecasting stock indices with back propagation neural network10.1016/j.eswa.2011.04.222 ↗
35. Efficient stock-market prediction using ensemble support vector machine10.1515/comp-2020-0199 ↗
36. Forecasting stock prices from the limit order book using convolutional neural networks10.1109/CBI.2017.23 ↗
37. Deep learning for finance: Deep portfolios10.1002/asmb.2209 ↗
38. Huang, J., Chai, J., and Cho, S. (2020). Deep learning in finance and banking: A literature review and classification. Front. Bus. Res. China, 14.10.1186/s11782-020-00082-6 ↗
39. Financial Time Series Forecasting Based on LSTM Neural Network optimized by Wavelet Denoising and Whale Optimization Algorithm
40. Deep learning networks for stock market analysis and prediction: Methodology, data representations, and case studies10.1016/j.eswa.2017.04.030 ↗
41. Nelson, D.M.Q., Pereira, A.C.M., and De Oliveira, R.A. (2017, January 14–19). Stock market’s price movement prediction with LSTM neural networks. Proceedings of the 2017 International Joint Conference on Neural Networks (IJCNN), Anchorage, AK, USA.10.1109/IJCNN.2017.7966019 ↗
42. Study on the prediction of stock price based on the associated network model of LSTM10.1007/s13042-019-01041-1 ↗
43. Rasheed, J., Jamil, A., Hameed, A.A., Ilyas, M., Özyavaş, A., and Ajlouni, N. (2020, January 26–27). Improving stock prediction accuracy using cnn and lstm. Proceedings of the 2020 International Conference on Data Analytics for Business and Industry: Way Towards a Sustainable Economy (ICDABI), Sakheer, Bahrain.10.1109/ICDABI51230.2020.9325597 ↗
44. A review of recurrent neural networks: LSTM cells and network architectures10.1162/neco_a_01199 ↗
45. Staudemeyer, R.C., and Morris, E.R. (2019). Understanding LSTM—A tutorial into long short-term memory recurrent neural networks. arXiv.
46. Particle swarm optimization10.1109/ICNN.1995.488968 ↗
47. Attention based spatiotemporal graph attention networks for traffic flow forecasting10.1016/j.ins.2022.05.127 ↗
48. Ant colony optimization10.1109/MCI.2006.329691 ↗
49. Bat algorithm: A novel approach for global engineering optimization10.1108/02644401211235834 ↗
50. Estimating soil moisture content in citrus orchards using multi-temporal sentinel-1A data-based LSTM and PSO-LSTM models10.1016/j.jhydrol.2024.131336 ↗
51. Han, L., Wang, X., Yu, Y., and Wang, D. (2024). Power Load Forecast Based on CS-LSTM Neural Network. Mathematics, 12.10.3390/math12091402 ↗
52. Hybrid LSTM-transformer model for emotion recognition from speech audio files10.1109/ACCESS.2022.3163856 ↗
53. Oreshkin, B.N., Carpov, D., Chapados, N., and Bengio, Y. (2019). N-BEATS: Neural basis expansion analysis for interpretable time series forecasting. arXiv.
54. Kabir, M.R., Bhadra, D., Ridoy, M., and Milanova, M. (2025). LSTM–Transformer-Based Robust Hybrid Deep Learning Model for Financial Time Series Forecasting. Sci, 7.10.3390/sci7010007 ↗
55. Yu, H. (2024, January 26–28). Comparative analysis of LSTM and transformer-based models for stock price forecasting. Proceedings of the AIP Conference Proceedings, Shanghai, China.10.1063/5.0227011 ↗
56. Vuković, D.B., Radenković, S.D., Simeunović, I., Zinovev, V., and Radovanović, M. (2024). Predictive patterns and market efficiency: A deep learning approach to financial time series forecasting. Mathematics, 12.10.3390/math12193066 ↗
57. Feoktistov, V. (2006). Differential Evolution, Springer.
58. Mirjalili, S., and Mirjalili, S. (2019). Genetic algorithm. Evolutionary Algorithms and Neural Networks: Theory and Applications, Springer.10.1007/978-3-319-93025-1 ↗
59. Frazier, P.I. (2018). Bayesian optimization. Recent Advances in Optimization and Modeling of Contemporary Problems, Informs.10.1287/educ.2018.0188 ↗