Vokasi UNESA Bulletin of Engineering, Technology and Applied Science
Vol. 3 No. 1 (2026)

Stock Price Forecasting Using LSTM with Cross-Validation

Rifki Ainul Yaqin (Adhirajasa Reswara Sanjaya (ARS) University)
Muhammad Iqbal Anshori (Adhirajasa Reswara Sanjaya (ARS) University)
Reddis Angel (Adhirajasa Reswara Sanjaya (ARS) University)
Ignatius Wiseto Prasetyo Agung (Adhirajasa Reswara Sanjaya (ARS) University)
Toni Arifin (Adhirajasa Reswara Sanjaya (ARS) University)
Erfian Junianto (Adhirajasa Reswara Sanjaya (ARS) University)



Article Info

Publish Date
22 Jan 2026

Abstract

Stock price forecasting is highly challenging due to the market’s nonlinear, volatile nature, which is influenced by complex economic and behavioral factors. Traditional statistical models and many machine learning approaches often suffer from overfitting and limited generalizability. This study examines the effectiveness of Long Short-Term Memory (LSTM) networks combined with k-Fold Cross-Validation as a lightweight yet robust alternative. Unlike Transformer-based models, which require extensive computational resources,LSTM offers a more resource-efficient solution while effectively capturing temporal dependencies in financial time series. Experiments were conducted on six U.S. stocks (LW, LKQ, IPG, MGM, RL, and CAG) across 1,000 training epochs, using one to two LSTM layers (64–128 hidden units) with the Adam optimizer. Model performance was evaluated using RMSE, MAE, and R² under k-Fold Cross-Validation and compared against Split Validation from prior studies. Results show that k-Fold consistently produced lower error values, confirming its reliability for stable performance estimation. Notably, models using Close-only input achieved lower RMSE and MAE than those with additional indicators (MA200, stochastic), which primarily improved R². This indicates that feature simplicity, combined with robust preprocessing and validation, can outperform more complex inputs in short-term forecasting. In conclusion, integrating LSTM with k-Fold Cross-Validation provides a practical and efficient framework for stock prediction, particularly in resource-constrained settings. However, the findings are limited to specific stocks and indicators. Future work should extend the approach to broader markets, incorporate macroeconomic or sentiment-based features, and explore hybrid architectures to enhance predictive performance further.

Copyrights © 2026






Journal Info

Abbrev

vubeta

Publisher

Subject

Computer Science & IT Engineering Mechanical Engineering Transportation

Description

Vokasi Unesa Bulletin Of Engineering, Technology and Applied Science is a peer-reviewed, Quarterly International Journal, that publishes high-quality theoretical and experimental papers of permanent interest, that have not previously been published in a journal, in the field of engineering, ...