Stock Price Prediction Using Machine Learning - Based on RNN Algorithms

Authors

  • Akhiyar Waladi Universitas Jambi Author
  • Yogi Perdana Universitas Jambi Author
  • Hasanatul Iftitah Universitas Jambi Author
  • Nindy Raisa Hanum Universitas Jambi Author

DOI:

https://doi.org/10.62205/dg2h0j98

Keywords:

Recurrent Neural Network (RNN), Stock Price Prediction,, Bank Rakyat Indonesia (BRI), Time Series Analysis, Machine Learning, Market Conditions, Investment Decision Support

Abstract

A Recurrent Neural Network (RNN) model has been developed to predict Bank Rakyat Indonesia (BRI) stock prices through extensive parameter optimization using grid search. The optimal configuration was achieved with an architecture of 150 RNN units, batch size of 32, learning rate of 0.001, and training process over 100 epochs. The model achieved its best performance with MSE of 12924.081, RMSE of 113.6841, MAE of 86.0699, R² of 0.749, and MAPE of 1.7438%. Error distribution analysis revealed the model's tendency to slightly underestimate with a mean error of -23.9 and standard deviation of 111.14. Time step importance evaluation showed that data from the last 7-8 days had the greatest influence on predictions. The model demonstrated best performance in sideways market conditions (R² 0.6833, MAPE 1.99%) compared to bull market (R² 0.4155, MAPE 3.02%) and bear market (R² 0.0505, MAPE 3.30%). Visual analysis confirmed the model's ability to follow long-term trends while maintaining measured responses to short-term volatility. The research results indicate that the developed RNN model can serve as a reliable investment decision support tool, particularly in relatively stable market conditions.

Downloads

Published

2024-11-23

Issue

Section

Articles