This is a replication study of the research paper "Bitcoin Price Prediction Using N-BEATS ML Technique" published in EAI Endorsed Transactions on Scalable Information Systemsby by G. Asmat and K. M. Maiyama. The project evaluates the efficacy of the Neural Basis Expansion Analysis Time Series (N-BEATS) architecture in forecasting Bitcoin prices, specifically focusing on its ability to handle the extreme volatility, nonlinearity and stochasity of cryptocurrency markets.
Cryptocurrency markets are characterized by high-frequency fluctuations and non-linear dependencies. This project demonstrates how the N-BEATS deep learning architecture provides a robust prediction by decomposing time series into interpretable trend and seasonality components comparing to traditional models such as Linear Regression and Long-Short-Term-Memory (LSTM) network.
- Data: Most recent 729 days of hourly Bitcoin price data, sourced from Yahoo Finance.
-
Pre-processing:
- Implementation of Min-Max scaling to normalize features (Open, High, Low, Close, Adj Close, Volume).
- Data reshaping into 3D structures for compatibility with deep learning layers.
- Model: The N-BEATS model utilizes a series of stacks and blocks to perform "backcasting" and "forecasting," allowing the network to identify complex temporal patterns without manual feature engineering.
- Prediction: Application of a 3-hour look-back window to predict the subsequent hour's High and Low prices.
-
Evaluation:
-
R-squared (
$R^2$ ): indicating the percentage of variation in a dependent variable that is explained by an independent variable(s) in a regression model. It's Ranging from 0 to 1 (0% to 100%), it represents how well a model fits the data, with 1 indicating a perfect fit. - Mean Absolute Error (MAE): a foundational regression model metric that measures the average magnitude of errors between predicted and actual values.It's calculated as the average of the absolute differences, lower MAE scores (0 is ideal) indicate better performance:
-
R-squared (
- Performance Comparison:
| Model |
|
Mean Absolute Error (MAE) |
|---|---|---|
| N-BEATS | 0.998924 | 0.00220156367 |
| Linear Regression | 0.9645 | 0.008994 |
| LSTM network | 0.9263 | 0.04753 |
- Interpretability: Decomposition of predictions into trend and seasonality blocks.
- Results: The N-BEATS model demonstrated superior performance in capturing Bitcoin's volatile price movements compared to traditional and recurrent neural network baselines, particularlly, a robust trend capturing during high-volatility periods.
The Neural Basis Expansion Analysis for Time Series (N-BEATS) is a deep learning architecture specifically engineered for time series forecasting without the need for domain-specific feature engineering. It is characterized by a hierarchical structure of blocks and stacks that utilize fully connected layers and residual connections to decompose data into interpretable signals like trend and seasonality.
For each block
Where
The forecast (
The basis functions
The input for the next block (
This enables the "decomposition" mentioned in the paper, as each block subtracts what it has already "explained" from the input.
The final prediction (
This summation allows the model to combine short-term oscillations and long-term trends into a single, highly accurate Bitcoin price prediction.
Predetermined hyperparemeters which is the same as the replicated paper
| Hyperparameters | Values |
|---|---|
| Sequence Length | 3 hours |
| Number of blocks | 3 |
| Units per block | 128 |
| Forecast dimension | 2 |
| Batch size | 64 |
| Epochs | 50 |
| Optimizer | Adam |
- Language:
Python 3.12 64-bit - Libraries: :
Pandas: data structural manipulationNumPy: reshaping the datayfinance: data acquisition for historial Bitcoin dataScikit-Learn: data processing, model selection by quantifying performance metrics, Train-Test sets model developmentTensorFlow 2.20.0,Keras: deep learning framework to construct N-BEATS architecture with layersOpenBB: collect unified data router and toolbox for financial analysisMatplotlib: create data visulization
- Environment:
Jupyter Notebook
-
Asmat, G., and K. M. Maiyama. “Bitcoin Price Prediction Using N-Beats ML Technique.” EAI Endorsed Transactions on Scalable Information Systems, April 1, 2025. https://doi.org/10.4108/eetsis.9006.
-
Mann , William. Quantitative Alpha In Crypto Markets: A Systematic Review of Factor Models, Arbitrage Strategies, and Machine Learning Applications. HarmoniQ Insights, Quantitative Research and Technology Advisors, 2025. https://papers.ssrn.com/sol3/papers.cfm?abstract_id=5225612.
-
Maswood, Mirza Mohd, and Abdullah G. Alharbi. “Deep Learning-Based Stock Price Prediction Using LSTM and Bi-Directional LSTM Model.” 2020 2nd Novel Intelligent and Leading Emerging Sciences Conference (NILES), October 24, 2020, 87–92. https://doi.org/10.1109/niles50944.2020.9257950.
-
Nakamoto, Satoshi. Bitcoin: A peer-to-peer electronic cash system, 2008. https://bitcoin.org/bitcoin.pdf.
-
Oreshkin, Boris N., Dmitri Carpov, Nicolas Chapados, and Yoshua Bengio. “N-Beats: Neural Basis Expansion Analysis for Interpretable Time Series Forecasting.” arXiv.org, February 20, 2020. https://arxiv.org/abs/1905.10437.
-
Shumway, Robert H., and David S. Stoffer. “ARIMA Models. In: Time Series Analysis and Its Applications.” SpringerLink, January 1, 1970.
-
Wang, Minxing, Pavel Braslavski, and Dmitry I. Ignatov. “TimeGPT’s Potential in Cryptocurrency Forecasting: Efficiency, Accuracy, and Economic Value.” Forecasting 7, no. 3 (September 10, 2025): 48. https://doi.org/10.3390/forecast7030048.
I am deeply grateful to William Mann, the Managing Partner of HarmoniQ Insights, for the invaluable insights and technical codebase provided in his 2025 research, which served as a foundational resource for the implementation and validation of this replication study.

