Optimizing deep learning techniques with stacking BiLSTM and BiGRU models for gold price prediction

Main Article Content

DOI

Iqbal Kharisudin

iqbalkharisudin@mail.unnes.ac.id

https://orcid.org/0000-0002-1156-4974
Nike Yustina Oktaviani

nikeyustina12.o@gmail.com

Abstract

Gold, essential in various sectors from jewelry to financial reserves, plays a crucial role as a financial asset and investment. Accurate prediction of gold prices is vital for informed investment decisions and economic management. This study utilizes a Stacking Ensemble approach to enhance gold price prediction accuracy by combining Bidirectional Long Short-Term Memory (BiLSTM) and Bidirectional Gated Recurrent Unit (BiGRU) as base learners, with Random Forest serving as the meta-learner. This method capitalizes on BiLSTM and BiGRU’s strengths in processing sequential data in both directions, capturing intricate patterns in gold price fluctuations. The dataset spans from January 1, 2020, to May 31, 2024. The results reveal that the Stacking Ensemble model with BiLSTM-BiGRU consistently outperforms other models, achieving the lowest Mean Squared Error (MSE) of 0.000, Root Mean Squared Error (RMSE) of 0.0067, Mean Absolute Error (MAE) of 0.0050, Mean Absolute Percentage Error (MAPE) of 0.0083, and a high R-squared value of 0.9984 across various lookback periods (7, 15, and 30 days). These metrics underscore the method’s effectiveness in accurately capturing and predicting gold price trends. This confirms that the Stacking Ensemble approach significantly enhances gold price prediction accuracy.

Keywords:

stacking ensemble, deep learning, BiLSTM, BiGRU, gold price forecasting

References

Article Details

Kharisudin, I., & Oktaviani, N. Y. (2025). Optimizing deep learning techniques with stacking BiLSTM and BiGRU models for gold price prediction. Informatyka, Automatyka, Pomiary W Gospodarce I Ochronie Środowiska, 15(3), 123–130. https://doi.org/10.35784/iapgos.6955