Open Access iconOpen Access

ARTICLE

Research on Stock Price Prediction Method Based on the GAN-LSTM-Attention Model

by Peng Li, Yanrui Wei, Lili Yin*

College of Computer Science and Technology, Harbin University of Science and Technology, Harbin, 150006, China

* Corresponding Author: Lili Yin. Email: email

Computers, Materials & Continua 2025, 82(1), 609-625. https://doi.org/10.32604/cmc.2024.056651

Abstract

Stock price prediction is a typical complex time series prediction problem characterized by dynamics, nonlinearity, and complexity. This paper introduces a generative adversarial network model that incorporates an attention mechanism (GAN-LSTM-Attention) to improve the accuracy of stock price prediction. Firstly, the generator of this model combines the Long and Short-Term Memory Network (LSTM), the Attention Mechanism and, the Fully-Connected Layer, focusing on generating the predicted stock price. The discriminator combines the Convolutional Neural Network (CNN) and the Fully-Connected Layer to discriminate between real stock prices and generated stock prices. Secondly, to evaluate the practical application ability and generalization ability of the GAN-LSTM-Attention model, four representative stocks in the United States of America (USA) stock market, namely, Standard & Poor’s 500 Index stock, Apple Incorporated stock, Advanced Micro Devices Incorporated stock, and Google Incorporated stock were selected for prediction experiments, and the prediction performance was comprehensively evaluated by using the three evaluation metrics, namely, mean absolute error (MAE), root mean square error (RMSE), and coefficient of determination (R2). Finally, the specific effects of the attention mechanism, convolutional layer, and fully-connected layer on the prediction performance of the model are systematically analyzed through ablation study. The results of experiment show that the GAN-LSTM-Attention model exhibits excellent performance and robustness in stock price prediction.

Keywords


Cite This Article

APA Style
Li, P., Wei, Y., Yin, L. (2025). Research on stock price prediction method based on the gan-lstm-attention model. Computers, Materials & Continua, 82(1), 609-625. https://doi.org/10.32604/cmc.2024.056651
Vancouver Style
Li P, Wei Y, Yin L. Research on stock price prediction method based on the gan-lstm-attention model. Comput Mater Contin. 2025;82(1):609-625 https://doi.org/10.32604/cmc.2024.056651
IEEE Style
P. Li, Y. Wei, and L. Yin, “Research on Stock Price Prediction Method Based on the GAN-LSTM-Attention Model,” Comput. Mater. Contin., vol. 82, no. 1, pp. 609-625, 2025. https://doi.org/10.32604/cmc.2024.056651



cc Copyright © 2025 The Author(s). Published by Tech Science Press.
This work is licensed under a Creative Commons Attribution 4.0 International License , which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.
  • 590

    View

  • 366

    Download

  • 0

    Like

Share Link