Claim Missing Document
Check
Articles

Found 1 Documents
Search
Journal : mathematical and data analytics

Implementation of Bidirectional LSTM with Attention Mechanism for Predicting BTC Prices Cahyo Adi Nugroho
Mathematical and Data Analytics Vol. 3 No. 1 (2026): Artikel Riset Juni 2026
Publisher : Yayasan Cita Cendikiawan Alkhwarizmi

Show Abstract | Download Original | Original Source | Check in Google Scholar | DOI: 10.47709/mda.v3i1.8359

Abstract

Bitcoin price prediction remains a challenging task due to its high volatility and noisy market behavior, particularly in short-horizon forecasting. This study proposes the implementation of a Bidirectional Long Short-Term Memory (BiLSTM) model enhanced with an Attention mechanism to improve the predictive performance of Bitcoin (BTC) returns. The model was compared against a standard BiLSTM and a Gated Recurrent Unit (GRU) using hourly BTC/USD data from the Kraken exchange covering the period from 2021 onwards. Comprehensive feature engineering was performed, incorporating technical indicators such as Relative Strength Index (RSI), Moving Average Convergence Divergence (MACD), Bollinger Bands width, trading volume, and volatility, along with rolling cumulative returns (Ret?? and Ret??). The prediction target was defined as the 6-hour ahead cumulative return. Model performance was rigorously evaluated using Walk-Forward Validation to simulate real-world out-of-sample testing. Experimental results showed that the BiLSTM with Attention mechanism achieved the best predictive performance among the tested models, with an average R² of -0.00627. However, all models produced negative R² values and directional accuracy close to 50%, indicating limited ability to outperform a simple mean return baseline. In the trading simulation with 0.1% transaction cost, all strategies yielded significant losses ranging from -48.23% to -91.88%. The Attention mechanism provided marginal improvements in R² but did not translate into superior trading performance. These findings highlight the inherent difficulty of short-horizon Bitcoin price prediction and suggest that integrating attention mechanisms alone may not be sufficient to capture meaningful patterns in highly noisy cryptocurrency markets. Future research should explore longer forecasting horizons, additional exogenous features such as market sentiment, and more advanced hybrid architectures.