Comparing Linear Regression, Random Forest, and LSTM for Antam Gold Price Forecasting
DOI:
https://doi.org/10.64366/ijids.v3i2.567Keywords:
Antam Gold Price; Gold Price Forecasting; Time-Series Forecasting; Linear Regression; Random Forest; Long Short-Term Memory (LSTM)Abstract
Forecasting gold prices plays a crucial role in supporting investment decision-making and financial risk management, particularly in Indonesia, where Antam gold is widely used as an investment instrument. Although numerous forecasting techniques have been proposed, comparative studies evaluating statistical, machine learning, and deep learning models for Antam gold price prediction using long-term historical data remain limited. A systematic comparison is therefore important to identify forecasting approaches that can provide reliable and interpretable predictions for the Indonesian gold market, especially when different lengths of historical data are considered. This study compares the forecasting performance of Linear Regression, Random Forest, and Long Short-Term Memory (LSTM) using historical Antam gold price data spanning January 2010 to June 2026, collected from Kaggle and the official Logam Mulia website. The preprocessing stage included date parsing, chronological sorting, missing value inspection, data normalization for LSTM, lag feature engineering, and sequence construction. Five experimental scenarios were designed to investigate the influence of historical data length on forecasting accuracy. Model performance was evaluated using Mean Absolute Error (MAE), Mean Squared Error (MSE), Root Mean Squared Error (RMSE), and the Coefficient of Determination (R²), with RMSE selected as the primary evaluation metric. The experimental results show that Linear Regression consistently achieved the best forecasting performance across all scenarios. The highest prediction accuracy was obtained using the 10-year historical data scenario, resulting in an RMSE of 17,064.29 and an R² of 0.9978. Random Forest produced competitive results only when the training dataset contained the highest observed gold price, whereas LSTM did not outperform Linear Regression in any experimental scenario. These findings demonstrate that, for Antam gold price forecasting with predominantly linear historical trends, a simple and interpretable statistical model can outperform more complex machine learning and deep learning approaches. Practically, the findings can support investors, financial analysts, and policymakers in Indonesia in selecting appropriate forecasting methods and developing more evidence-based investment strategies and financial risk management policies. The results also highlight the importance of selecting an appropriate historical data length to achieve reliable forecasting performance in financial time-series applications.
Downloads
References
L. D. Jayanti, R. Lestari, F. A. D. Suparno, and Fachruzzaki, “Metode Autoregressive Integrated Moving Average ( ARIMA ) pada Aplikasi RStudio,” MARAS J. Penelit. Multidisplin, vol. 3, no. 4, pp. 1275–1289, 2025, doi: 10.60126/maras.v3i4.1253.
B. A. Tengger and I. Reviladi, “Aplikasi Holt’s Linear Trend Exponential Smoothing Dalam Prediksi Harga Emas Di Indonesia,” Prox. J. Penelit. Mat. dan Pendidik. Mat., vol. 8, no. 4, pp. 1187–1194, 2025, doi: 10.30605/proximal.v8i4.7367.
Y. Sari, A. A. T. Susilo, and L. Sunardi, “Prediksi Harga Emas Mengunakan Jaringan Saraf Tiruan Algoritma Backpropagation,” Bull. Comput. Sci., vol. 5, no. 4, pp. 831–840, 2025, doi: 10.47065/bulletincsr.v5i4.566.
B. Arham, Sukasih, and R. Sani, “Prediksi Harga Emas Harian Dan Multi-Horizon Menggunakan ARIMA, LSTM Dan Model Hybrid ARIMA-LSTM,” J. Sains Inform. Terap., vol. 5, no. 1, pp. 18–23, 2026, doi: 10.62357/jsit.v5i1.935.
W. Gong, “Research on gold price forecasting based on lstm and linear regression,” in SHS Web of Conferences, 2024, vol. 02005, pp. 1–5. doi: 10.1051/shsconf/202418102005.
H. Aljohani, S. Alshamrani, N. Aljojo, A. Tashkandi, And T. Alsahfi, “Predicting monthly gold prices in indian rupees using ARIMA, LSTM, GRU, and Simple Linear Regression models,” Rom. J. Inf. Technol. Autom. Control, vol. 34, no. 2, pp. 35–47, 2024, doi: 10.33436/v34i2y202403.
Ayu Ahadi Ningrum, I. Syarif, A. I. Gunawan, E. Satriyanto, and R. Muchtar, “Algoritma Deep Learning-LSTM Untuk Memprediksi Umur Transformer,” J. Teknol. Inf. dan Ilmu Komput., vol. 8, no. 3, pp. 539–548, 2021, doi: 10.25126/jtiik.202184587.
A. Rahmat, M. Syafiih, and M. Faid, “Implementasi Klasifikasi Potensi Penyakit Jantung Dengan Menggunakan Metode C4.5 Berbasis Website ( Studi Kasus Kaggle.Com ),” INFOTECH J., vol. 9, no. 2, pp. 393–400, 2023, doi: 10.31949/infotech.v9i2.6295.
A. Agung, A. Daniswara, and I. K. D. Nuryana, “Data Preprocessing Pola Pada Penilaian Mahasiswa Program Profesi Guru,” J. Informatics Comput. Sci., vol. 05, no. 01, pp. 97–100, 2023, doi: 10.26740/jinacs.v5n01.p97-100.
P. D. Quang and T. Q. Thang, “Analysis and forecasting of daily global gold price?: an SARIMA-LSTM approach with Random Forest technique,” Cogent Econ. Financ., vol. 13, no. 1, pp. 1–16, 2025, doi: 10.1080/23322039.2025.2568969.
M. Kumar and V. Bhardwaj, “Evaluating Label Encoding and Preprocessing Techniques for Breast Cancer Prediction Using Machine Learning Algorithms,” Int. J. Comput. Intell. Syst., vol. 18, no. 218, pp. 1–35, 2025, doi: 10.1007/s44196-025-00957-7.
D. U. Ozsahin, M. T. Mustpha, and A. S. Mubarak, “Impact of feature scaling on machine learning models for the diagnosis of diabetes,” in International Conference on Artificial Intelligence in Everything (AIE) 2022, 2022, pp. 87–94. doi: 10.1109/AIE57029.2022.00024.
F. A. Mohammad, A. M. Rizki, and A. N. Sihananto, “Peramalan Tingkat Inflasi Di Indonesia Menggunakan Artificial Bee Colony Dan Xgboost,” JITET (Jurnal Inform. dan Tek. Elektro Ter., vol. 12, no. 3, pp. 2614–2623, 2024, doi: 10.23960/jitet.v12i3.4827.
C. Fieberg, D. Metko, T. Poddig, and T. Loy, “Machine learning techniques for cross?sectional equity returns’ prediction,” OR Spectr., vol. 45, no. 1, pp. 289–323, 2023, doi: 10.1007/s00291-022-00693-w.
G. Cohen and A. Aiche, “Forecasting gold price using machine learning methodologies,” Chaos, Solitons & Fractals, vol. 175, p. 114079, 2023, doi: https://doi.org/10.1016/j.chaos.2023.114079.
S. Hochreiter, “Long Short-Term Memory,” Neural Comput. 9, vol. 9, no. 8, pp. 1735–1780, 1997, doi: 10.1162/neco.1997.9.8.1735.
T. Lattifiaa, P. W. Buanaa, and N. K. D. Rusjayanthi, “Model Prediksi Cuaca Menggunakan Metode LSTM,” JITTER- J. Ilm. Teknol. dan Komput., vol. 3, no. 1, pp. 1–6, 2022.
A. Amini and R. Kalantari, “Gold price prediction by a CNN-Bi-LSTM model along with automatic parameter tuning,” PLoS One, pp. 1–17, 2024, doi: 10.1371/journal.pone.0298426.
Fitria, M. S. Pebriadi, and N. L. Putri, “Short-Term and Long-Term Forecasting of Global Gold Prices Using LSTM and GRU Models,” JISA (Jurnal Inform. dan Sains), vol. 09, no. 01, pp. 25–29, 2026, doi: 10.31326/jisa.v9i1.2723.
R. Septiana et al., “Prediksi Harga Emas Indonesia Menggunakan Model CNN-LSTM,” INFOMATEK J. Inform. Manaj. dan Teknol., vol. 27, no. 1, pp. 131–138, 2025, doi: 10.23969/infomatek.v27i1.24417.
M. A. Vega, R. Gustriansyah, and I. Permatasari, “Predicting Precious Metal Prices Using the Long-Short-Term Memory ( LSTM ) Method,” Bit-Tech(Binary Digit. -Technology), vol. 8, no. 2, pp. 1528–1537, 2025, doi: 10.32877/bt.v8i2.2985.
A. Ashari, Z. Situmorang, and R. Rosnelly, “Long Short Term Memory and Gradient Boosting Model for One Day Ahead Forecasting of ANTAM Gold Bar Prices,” J. Tek. Inform., vol. 7, no. 2, pp. 1704–1713, 2026, doi: 10.52436/1.jutif.2026.7.2.5630.
R. N. Adila and Abdurakhman, “Gold Price Forecasting with Long Short Term Memory ( LSTM ) and ARIMAX Method,” Indones. J. Appl. Stat., vol. 8, no. 2, pp. 102–112, 2025, doi: 10.13057/ijas.v8i2.97739.1.
Y. Alkhalifi, “Comparative Forecasting of Antam Gold Prices Using LSTM , GRU , and Hybrid LSTM – GRU with Adam and SGD Optimizers,” MEDIA Elektr. J., vol. 23, no. 3, pp. 313–322, 2026, [Online]. Available: https://journal.unm.ac.id/index.php/mediaelektrik/article/view/13794/8789
Bila bermanfaat silahkan share artikel ini
Berikan Komentar Anda terhadap artikel Comparing Linear Regression, Random Forest, and LSTM for Antam Gold Price Forecasting
ARTICLE HISTORY
How to Cite
Issue
Section
Copyright (c) 2026 Mohamad Ilyas Abas, Rozmin binti Mohamad Rasli, Fudlail Ziqry Maulana Hadi, Arthur Gani Koto

This work is licensed under a Creative Commons Attribution 4.0 International License.
Authors who publish with this journal agree to the following terms:
- Authors retain copyright and grant the journal right of first publication with the work simultaneously licensed under Creative Commons Attribution 4.0 International License that allows others to share the work with an acknowledgment of the work's authorship and initial publication in this journal.
- Authors are able to enter into separate, additional contractual arrangements for the non-exclusive distribution of the journal's published version of the work (e.g., post it to an institutional repository or publish it in a book), with an acknowledgment of its initial publication in this journal.
- Authors are permitted and encouraged to post their work online (e.g., in institutional repositories or on their website) prior to and during the submission process, as it can lead to productive exchanges, as well as earlier and greater citation of published work (Refer to The Effect of Open Access).






