Application of LSTM, RNN, and Transformer in Stock Price Prediction of Information Technology Companies: A Comparative Analysis
This research presents a comparative analysis of the Long Short-Term Memory (LSTM), Recurrent Neural Network (RNN), and Transformer models in predicting the stock prices with a multi-step prediction approach of five major information technology companies—Capgemini, Infosys, IBM Consulting, NTT Data, and Cognizant. The study uses historical stock data from 2018 to 2023, employing the Knowledge Discovery in Databases (KDD) methodology. This research also added Moving Average Convergence Divergence (MACD) analysis to identify stock momentum trends. The models were evaluated based on prediction accuracy (Mean Absolute Error and Mean Squared Error), training time, and memory usage. Results indicate that while the Transformer model outperforms LSTM and RNN in accuracy, it demands higher computational resources. RNN showed faster training times but moderate prediction accuracy, and LSTM had lower performance but was more memory efficient. MACD analysis revealed balanced trends in Golden Cross and Death Cross patterns across companies, with higher Golden Cross frequencies signaling favorable stock performance. This research offers valuable insights for investors in selecting suitable prediction models and highlights the potential for future application of these models across different industries.
Authors
- Hanif Fakhrurroja (ORCID: https://orcid.org/0000-0002-2483-251X)
- Putri Utami Rukmana
- Asriana
Institutions
- Telkom University (ID)
Publication Details
- Published
- 2024-10-09
- DOI
- https://doi.org/10.1109/ic3ina64086.2024.10732754
- Citations
- 8
- Primary Topic
- Stock Market Forecasting Methods
- Type
- article
- Field-Weighted Citation Impact
- 3.92