UPM Institutional Repository

Optimising LSTM and BiLSTM models for time series forecasting through hyperparameter tuning


Citation

Abd Rahman, Nur Haizum and Yin, Quay Pin and Zulkafli, Hani Syahida (2025) Optimising LSTM and BiLSTM models for time series forecasting through hyperparameter tuning. Journal of Quality Measurement and Analysis, 21 (3). pp. 191-205. ISSN 1823-5670; eISSN: 2600-8602

Abstract

Long Short-Term Memory (LSTM) and Bidirectional Long Short-Term Memory (BiLSTM) are the emerging Recurrent Neural Networks (RNN) widely used in time series forecasting. The performance of these neural networks relies on the selection of hyperparameters. A random selection of the hyperparameters may increase the forecasting error. Hence, this study aims to optimise the performance of LSTM and BiLSTM in time series forecasting by tuning one of the essential hyperparameters, the number of hidden neurons. LSTM and BiLSTM with 32, 64, and 128 hidden neurons and various combinations of other hyperparameters are formed in this study through grid searching. The models are evaluated and compared based on the Mean Squared Error (MSE) and Mean Absolute Error (MAE). The results from real data analysis revealed that 128 hidden neurons are the optimum choice of hidden neurons with the lowest error values. This study investigates whether BiLSTM, performs better than LSTM in forecasting. Thus, the performance of these two neural networks in forecasting time series data was compared, and the Wilcoxon-Signed Rank Test was conducted. Results revealed a significant difference in the performance of these two neural networks, and BiLSTM outperformed LSTM in forecasting time series data. Hence, BiLSTM with 128 hidden neurons is encouraged to be chosen over LSTM in time series forecasting. Since these findings have implications for future practice, the combination of model and hyperparameter should be chosen wisely to obtain more accurate predictions in time series forecasting.


Download File

[img] Text
125268.pdf - Published Version
Restricted to Repository staff only

Download (847kB)

Additional Metadata

Item Type: Article
Subject: Economics and Econometrics
Divisions: Faculty of Science
DOI Number: https://doi.org/10.17576/jqma.2103.2025.12
Publisher: Penerbit Universiti Kebangsaan Malaysia
Keywords: BiLSTM; Deep learning; Forecasting; LSTM; Time series
Sustainable Development Goals (SDGs): SDG 9: Industry, Innovation and Infrastructure, SDG 17: Partnerships for the Goals, SDG 4: Quality Education
Depositing User: Ms. Nur Faseha Mohd Kadim
Date Deposited: 06 May 2026 05:10
Last Modified: 06 May 2026 05:10
Altmetrics: http://www.altmetric.com/details.php?domain=psasir.upm.edu.my&doi=10.17576/jqma.2103.2025.12
URI: http://psasir.upm.edu.my/id/eprint/125268
Statistic Details: View Download Statistic

Actions (login required)

View Item View Item