Research Article Open Access

Forecasting of Multistep Multivariate Financial Data Through GSO Algorithm Infused Vanilla LSTM Model

Nikhitha Pai1, Ilango Velchamy1 and Nithya B Ramesh2
  • 1 Department of MCA, CMR Institute of Technology, Bengaluru, India
  • 2 Department of MCA, New Horizon College of Engineering, Bengaluru, India

Abstract

Predicting time series in the financial domain requires using models that can do sequence processing tasks. One such model is the LSTM model which belongs to the family of deep learning networks. The performance measure of LSTM in a regression task is to bring down the error in the predicted values. In this study, a novel fused LSTM model integrating a glowworm optimization algorithm helps to do a multistep prediction of close stock prices of select companies from the FMCG sector of BSE and the consumables sector of NSE 50. The fused GSO algorithms are applied to LSTMs to bring down the difference between the predicted and real values. The reason for using GSO Infused LSTM implementation in this study is that pure LSTMs cannot give very good prediction results. Once the topology of the LSTM is tuned well the accuracy of prediction results improves considerably. This has been achieved with the GSO algorithm infused in the LSTM model. The justification for using optimization through GSO for the optimization of LSTMs is that it takes lesser time to converge than the gradient descent and gives faster results of better solutions compared to commonly used approaches like Grid search and Random search. Glowworm swarm optimization can also be used for easy convergence to optima in the case of multimodal functions. The results of the experiment show that there is a considerable reduction in the difference between actual and predicted values in the case of LSTMs interfaced with GSO when compared with other regressors like support vector regressor, KNN, random forest, and stacked LSTM and GRU models. For the Training set of data, the mean RMSE values for the different models were obtained as 270.17 for SVR, 21.16 for the random forest, 90.72 for KNN, 44.36 for stacked LSTM, 51.28 for GRU and 31.8 for vanilla LSTM GSO models. Similarly, a substantial difference in RMSE values was observed for a Test set of data such as 702.95 for SVR, 457.17 for RF, 447.5 for KNN, 211.03 for stacked LSTM, 211.05 for GRU and 38.85 for vanilla LSTM GSO. The least RMSE values were obtained in the case of the GSO LSTM model and there was not much variation in the training and test data values, which was existing in other models. In this study, a single CPU vanilla LTM model infused with GSO has been used. A parallel version of GSO could be applied successfully to enable parallelization. This would achieve scalability and efficiency.

Journal of Computer Science
Volume 19 No. 7, 2023, 909-924

DOI: https://doi.org/10.3844/jcssp.2023.909.924

Submitted On: 24 March 2023 Published On: 10 July 2023

How to Cite: Pai, N., Velchamy, I. & Ramesh, N. B. (2023). Forecasting of Multistep Multivariate Financial Data Through GSO Algorithm Infused Vanilla LSTM Model. Journal of Computer Science, 19(7), 909-924. https://doi.org/10.3844/jcssp.2023.909.924

  • 1,821 Views
  • 859 Downloads
  • 0 Citations

Download

Keywords

  • Glowworm Swarm Optimization Algorithm (GSO)
  • Long Short-Term Memory (LSTM)
  • Deep Learning
  • Machine Learning
  • Sliding Window Mechanism
  • Walk Forward Validation
  • Hyperparameter Tuning