Automated Bitcoin Trading dApp Using Price Prediction from a Deep Learning Model
Abstract
:1. Introduction
1.1. Problem Formulation
1.2. Objectives
1.3. Organization
2. Related Work
2.1. Cryptocurrency Price Prediction
2.2. Blockchain, Smart Contract, and Oracles
2.3. Decentralized Applications (dApps)
- DeFi (Decentralized Finance): These applications aim to recreate traditional financial systems such as lending, borrowing, and trading on the blockchain. Examples include Uniswap, Aave, and Compound.
- NFT (Non-Fungible Tokens): These are unique digital assets verified using blockchain technology. They are used in various fields such as art, gaming, and collectibles. Examples include CryptoKitties, NBA Top Shot, and OpenSea.
- GameFi (Gaming and DeFi): These applications combine gaming with financial incentives, allowing players to earn tokens through gameplay. Examples include Axie Infinity and Decentraland.
3. Our Methodology
3.1. Blockchain, Smart Contracts, and Oracle
3.1.1. Blockchain
3.1.2. Smart Contract
3.1.3. Oracle
3.2. System Architecture and Trading Flowchart
3.3. Machine Learning Models Used
3.3.1. Random Forest
3.3.2. LSTM
3.3.3. Bi-LSTM
3.4. Architecture Implementation of the System
3.5. Three-Stage Approach of the Crypto Trading System
- Bitcoin: Part of Bitcoin market data.
- Bitcoin Technologies: Related to variables derived from the Bitcoin codebase and node operations.
- Cryptocurrencies: Other currencies that are assumed to have price correlations.
- Commodities: Commodities that are assumed to influence cryptocurrency prices.
- Stock Markets: Key indexes that may affect cryptocurrency prices.
- Public Sentiment: Market behaviors can often be driven by emotions, leading to irrational decisions, especially in speculative assets like cryptocurrencies.
4. Experiments and Result Analysis
4.1. Experimental Results on Price Prediction
4.2. Experimental Results on Profitability of Portfolio Management
4.3. Result Comparisons with Prior Work
4.4. Discussions
5. Conclusions
Current Limitations and Future Works
Author Contributions
Funding
Data Availability Statement
Conflicts of Interest
References
- Adams, Austin, Xin Wan, and Noah Zinsmeister. 2023. UNISWAP v3 TWAP Oracles in Proof of Stake. Uniswap Protocol. Available online: https://blog.uniswap.org/uniswap-v3-oracles (accessed on 23 November 2023).
- Aivaz, Kamer-Ainur, Ionela Florea Munteanu, and Flavius Valentin Jakubowicz. 2023. Bitcoin in Conventional Markets: A Study on Blockchain-Induced Reliability, Investment Slopes, Financial and Accounting Aspects. Mathematics 11: 4508. [Google Scholar] [CrossRef]
- Akila, V., M. V. S. Nitin, I. Prasanth, Sandeep Reddy, and Akash Kumar. 2023. A Cryptocurrency Price Prediction Model using Deep Learning. Paper presented at the 4th International Conference on Design and Manufacturing Aspects for Sustainable Energy, Hyderabad, India, May 19–20. [Google Scholar]
- Alamsyah, Andry, Gede Natha Wijaya Kusuma, and Dian Puteri Ramadhani. 2024. A Review on Decentralized Finance Ecosystems. Future Internet 16: 76. [Google Scholar] [CrossRef]
- Ammous, Saifedean. 2016. Blockchain Technology: What Is It Good for? Preprint Available at SSRN. Available online: https://www.ssrn.com/abstract=2832751 (accessed on 10 November 2023).
- Andrei, Alexandru Gabriel. 2024. Hybrid Smart Contracts with Decentralized Oracles. Romanian Cyber Security Journal 1: 6. [Google Scholar] [CrossRef]
- Basher, Syed Abul, and Perry Sadorsky. 2022. Forecasting Bitcoin price direction with random forests: How important are interest rates, inflation, and market volatility? Machine Learning with Applications 9: 100355. [Google Scholar] [CrossRef]
- Benetti, Zeno, and Federico Piazza. 2023. Decentralised Finance: A categorisation of smart contracts. ESMA TRV Risk Analysis. Available online: https://www.esma.europa.eu/sites/default/files/2023-10/ESMA50-2085271018-3351_TRV_Article_Decentralised_Finance_A_Categorisation_of_Smart_Contracts.pdf (accessed on 7 January 2025).
- Benson, Vladlena, Umut Turksen, and Bogdan Adamyk. 2024. Dark side of decentralised finance: A call for enhanced AML regulation based on use cases of illicit activities. Journal of Financial Regulation and Compliance 32: 80–97. [Google Scholar] [CrossRef]
- Breidenbach, Lorenz, Christian Cachin, Benedict Chan, Alex Coventry, Steve Ellis, Ari Juels, Brendan Magauran, Sergey Nazarov, Alexandru Topliceanu, and Fan Zhang. 2021. Chainlink 2.0: Next Steps in the Evolution of Decentralised Oracle Networks. White Paper, vol. 1. Available online: https://research.chain.link/whitepaper-v2.pdf (accessed on 20 March 2024).
- Chatterjee, Indranath, Swapnajit Chakraborti, and Tanya Tono. 2024. Comparative study of bitcoin price prediction during pre-Covid19 and whilst-Covid19 period using time series and machine learning models. Discover Analytics 2: 19. [Google Scholar] [CrossRef]
- Chen, Junwei. 2023. Analysis of bitcoin price prediction using machine learning. Journal of Risk and Financial Management 16: 51. [Google Scholar] [CrossRef]
- Chen, Sheng, Qi Cao, and Yiyu Cai. 2023. Blockchain for Healthcare Games Management. Electronics 12: 3195. [Google Scholar] [CrossRef]
- Chicco, Davide, Matthijs J. Warrens, and Giuseppe Jurman. 2021. The coefficient of determination R-squared is more informative than smape, Mae, MAPE, MSE and RMSE in regression analysis evaluation. PeerJ Computer Science 7: e623. [Google Scholar] [CrossRef]
- CoinGecho.com. 2025. Global Cryptocurrency Market Cap Charts. Available online: https://www.coingecko.com/en/global-charts (accessed on 8 January 2025).
- Conlon, Thomas, Shaen Corbet, and Yang Hu. 2022. The Collapse of FTX: The End of Cryptocurrency’s Age of Innocence. The British Accounting Review, 101277. [Google Scholar] [CrossRef]
- De Mariz, Frederic. 2022. Cryptocurrencies: A Natural Evolution for Payments? In Finance with a Purpose: FinTech, Development and Financial Inclusion in the Global Economy. Singapore: World Scientific Publishing, pp. 111–26. [Google Scholar]
- Demirgüç-Kunt, Asli, Leora Klapper, Dorothe Singer, Saniya Ansar, and Jake Hess. 2018. The Global Findex Database 2017: Measuring Financial Inclusion and the Fintech Revolution. Washington, DC: World Bank Group. Available online: http://hdl.handle.net/10986/29510 (accessed on 7 January 2025).
- Di Pierro, Massimo. 2017. What Is the Blockchain? Computing in Science & Engineering 19: 92–95. [Google Scholar] [CrossRef]
- Dumiter, Florin Cornel, Florin Turcaș, Ștefania Amalia Nicoară, Cristian Bențe, and Marius Boiță. 2023. The Impact of Sentiment Indices on the Stock Exchange—The Connections between Quantitative Sentiment Indicators, Technical Analysis, and Stock Market. Mathematics 11: 3128. [Google Scholar] [CrossRef]
- El Hajj, Mohammad, and Imad Farran. 2024. The Cryptocurrencies in Emerging Markets: Enhancing Financial Inclusion and Economic Empowerment. Journal of Risk and Financial Management 17: 467. [Google Scholar] [CrossRef]
- Ferdiansyah, Ferdiansyah, Siti Hajar Othman, Raja Zahilah Raja Md Radzi, Deris Stiawan, Yoppy Sazaki, and Usman Ependi. 2019. A LSTM-Method for Bitcoin Price Prediction: A Case Study Yahoo Finance Stock Market. Paper presented at the 2019 International Conference on Electrical Engineering and Computer Science (ICECOS), Batam, Indonesia, October 2–3; pp. 206–10. [Google Scholar] [CrossRef]
- Goodell, John W., Sami Ben Jabeur, Foued Saâdaoui, and Muhammad Ali Nasir. 2023. Explainable artificial intelligence modeling to forecast bitcoin prices. International Review of Financial Analysis 88: 102702. [Google Scholar] [CrossRef]
- Gupta, Anuradha. 2022. Decentralized Finance: A Potential Paradigm Shift for Financial Inclusion and Economic Empowerment. International Journal of Finance and Management Research 4: 15509. [Google Scholar] [CrossRef]
- Hafid, Abdelatif, Abdelhakim Senhaji Hafid, and Mustapha Samih. 2020. Scaling Blockchains: A Comprehensive Survey. IEEE Access 8: 125244–62. [Google Scholar] [CrossRef]
- Haq, Inzamam Ul, Paulo Ferreira, Derick David Quintino, Nhan Huynh, and Saowanee Samantreeporn. 2023. Samantreeporn. Economic Policy Uncertainty, Energy and Sustainable Cryptocurrencies: Investigating Dynamic Connectedness during the COVID-19 Pandemic. Economies 11: 76. [Google Scholar] [CrossRef]
- Harvey, Campbell R., and Daniel Rabetti. 2024. International business and decentralized finance. International Business and Decentralized Finance 55: 840–63. [Google Scholar] [CrossRef]
- Hassan, Ammar, Imran Makhdoom, Waseem Iqbal, Awais Ahmad, and Asad Raza. 2023. From trust to truth: Advancements in mitigating the Blockchain Oracle problem. Journal of Network and Computer Applications 217: 103672. [Google Scholar] [CrossRef]
- Heiss, Jonathan, Jacob Eberhardt, and Stefan Tai. 2019. From oracles to trustworthy data on-chaining systems. Paper presented at the 2019 IEEE International Conference on Blockchain (Blockchain), Atlanta, GA, USA, July 14–17. [Google Scholar]
- Irresberger, Felix, Kose John, Peter Mueller, and Fahad Saleh. 2020. The public blockchain ecosystem: An empirical analysis. Preprint Available at SSRN. Available online: https://www.ssrn.com/abstract=3592849 (accessed on 10 November 2023).
- John, David L., Sebastian Binnewies, and Bela Stantic. 2024. Cryptocurrency Price Prediction Algorithms: A Survey and Future Directions. Forecasting 6: 637–71. [Google Scholar] [CrossRef]
- John, Kose, Leonid Kogan, and Fahad Saleh. 2023. Smart Contracts and Decentralized Finance. Annual Review of Financial Economics 15: 523–42. [Google Scholar] [CrossRef]
- Kang, Chuen Yik, Chin Poo Lee, and Kian Ming Lim. 2022. Cryptocurrency price prediction with convolutional neural network and stacked gated recurrent unit. Data 7: 149. [Google Scholar] [CrossRef]
- Kayani, Umar, and Fakhrul Hasan. 2024. Unveiling Cryptocurrency Impact on Financial Markets and Traditional Banking Systems: Lessons for Sustainable Blockchain and Interdisciplinary Collaborations. Journal of Risk and Financial Management 17: 58. [Google Scholar] [CrossRef]
- Khan, Shafaq Naheed, Faiza Loukil, Chirine Ghedira-Guegan, Elhadj Benkhelifa, and Anoud Bani-Hani. 2021. Blockchain Smart Contracts: Applications, challenges, and future trends. Peer-to-Peer Networking and Applications 14: 2901–25. [Google Scholar] [CrossRef]
- Kumar, Anoop S., and Suvvari Anandarao. 2019. Volatility spillover in crypto-currency markets: Some evidences from GARCH and wavelet analysis. Physica A: Statistical Mechanics and Its Applications 524: 448–58. [Google Scholar] [CrossRef]
- Li, Zongwei, Wenkai Li, Xiaoqi Li, and Yuqing Zhang. 2024. Guardians of the Ledger: Protecting Decentralized Exchanges from State Derailment Defects. IEEE Transactions on Reliability, 1–13. [Google Scholar] [CrossRef]
- Lu, Houhan. 2022. Bitcoin Trading using LSTM. Paper presented at the 2nd International Conference on Business Administration and Data Science, Shanghai, China, December 22–23; pp. 1457–71. [Google Scholar] [CrossRef]
- Lys, Léonard, and Maria Potop-Butucaru. 2022. Distributed Blockchain Price Oracle. Paper presented at the 10th International Conference on Networked Systems, Virtual Event, May 17–19; pp. 37–51. [Google Scholar] [CrossRef]
- Manoj, T., Krishnamoorthi Makkithaya, V. G. Narendra, and T. V. Murari. 2024. Blockchain Oracles for Decentralized Agricultural Insurance Using Trusted IoT Data. Frontier Blockchain 7: 1481339. [Google Scholar] [CrossRef]
- Mohan, C. 2019. State of public and private blockchains. Paper presented at the 2019 International Conference on Management of Data, Amsterdam, The Netherlands, June 30–July 5. [Google Scholar]
- Nagula, Pavan Kumar, and Christos Alexakis. 2022. A new hybrid machine learning model for predicting the bitcoin (BTC-USD) price. Journal of Behavioral and Experimental Finance 36: 100741. [Google Scholar] [CrossRef]
- Nakamoto, Satoshi. 2008. Bitcoin: A Peer-to-Peer Electronic Cash System. Available online: https://bitcoin.org/bitcoin.pdf (accessed on 10 November 2023).
- Omole, Oluwadamilare, and David Enke. 2024. Deep learning for Bitcoin price direction prediction: Models and trading strategies empirically compared. Financial Innovation 10: 117. [Google Scholar] [CrossRef]
- Otabek, Sattarov, and Jaeyoung Choi. 2024. Multi-level deep Q-networks for Bitcoin trading strategies. Scientific Reports 14: 771. [Google Scholar] [CrossRef] [PubMed]
- Pantin, Lynnise E. 2023. Financial Inclusion, Cryptocurrency, and Afrofuturism. 118 NW. U. L. REV. 621. Available online: https://scholarship.law.columbia.edu/faculty_scholarship/4183 (accessed on 7 January 2025).
- Parente, Mimmo, Luca Rizzuti, and Mario Trerotola. 2024. A profitable trading algorithm for cryptocurrencies using a neural network model. Expert Systems with Applications 238: 121806. [Google Scholar] [CrossRef]
- Parvini, Navid, Mahsa Abdollahi, Sattar Seifollahi, and Davood Ahmadian. 2022. Forecasting Bitcoin returns with long short-term memory networks and wavelet decomposition: A comparison of several market determinants. Applied Soft Computing, 121, 108707. [Google Scholar] [CrossRef]
- Pasdar, Amirmohammad, Young Choon Lee, and Zhongli Dong. 2023. Connect API with Blockchain: A survey on Blockchain Oracle Implementation. ACM Computing Surveys 55: 1–39. [Google Scholar] [CrossRef]
- Pines, Matthew, and David Zell. 2023. Proof of Reserves: A Report on Mitigating Crypto Custody Risk. Available online: https://www.btcpolicy.org/articles/proof-of-reserves-a-report-on-mitigating-crypto-custody-risk (accessed on 10 November 2023).
- Rehman, Muhammad Habibu, Khaled Salah, Ernesto Damiani, and Davor Svetinovic. 2020. Trust in Blockchain Cryptocurrency Ecosystem. IEEE Transactions on Engineering Management 67: 1196–212. [Google Scholar] [CrossRef]
- Seabe, Phumudzo Lloyd, Claude Rodrigue Bambe Moutsinga, and Edson Pindza. 2023. Forecasting cryptocurrency prices using LSTM, GRU, and bi-directional LSTM: A deep learning approach. Fractal and Fractional 7: 203. [Google Scholar] [CrossRef]
- Sebastião, Helder, and Pedro Godinho. 2021. Forecasting and trading cryptocurrencies with machine learning under changing market conditions. Financial Innovation 7: 1. [Google Scholar] [CrossRef] [PubMed]
- Sguanci, Cosimo, Roberto Spatafora, and Andrea Mario Vergani. 2021. Layer 2 Blockchain Scaling: A Survey. arXiv arXiv:2107.10881. [Google Scholar]
- Shah, Kaushal, Dhruvil Lathiya, Naimish Lukhi, Keyur Parmar, and Harshal Sanghvi. 2023. A systematic review of decentralized finance protocols. International Journal of Intelligent Networks 4: 171–81. [Google Scholar] [CrossRef]
- Smutny, Zdenek, Zdenek Sulc, and Jan Lansky. 2021. Motivations, Barriers and Risk-Taking When Investing in Cryptocurrencies. Mathematics 9: 1655. [Google Scholar] [CrossRef]
- Statista.com. 2024a. Number of Cryptocurrencies Worldwide from 2013 to December 2024. Available online: https://www.statista.com/statistics/863917/number-crypto-coins-tokens/ (accessed on 11 December 2024).
- Statista.com. 2024b. Overall Cryptocurrency Market Capitalization Per Week from July 2010 to December 2024. Available online: https://www.statista.com/statistics/730876/cryptocurrency-maket-value/ (accessed on 11 December 2024).
- Syed, Sibtain, Arshad Iqbal, Waqar Mehmood, Zain Syed, Maqbool Khan, and Giovanni Pau. 2023. Split-Second Cryptocurrency Forecast Using Prognostic Deep Learning Algorithms: Data Curation by Deephaven. IEEE Access 11: 128644–54. [Google Scholar] [CrossRef]
- Tabash, Mosab I., Neenu Chalissery, T. Mohamed Nishad, and Mujeeb Saif Mohsen Al-Absy. 2024. Market Shocks and Stock Volatility: Evidence from Emerging and Developed Markets. International Journal of Financial Studies 12: 2. [Google Scholar] [CrossRef]
- Taherdoost, Hamed. 2023. Smart Contracts in Blockchain Technology: A Critical Review. Information 14: 117. [Google Scholar] [CrossRef]
- The WFE Statistics Team. 2024. Market Statistics—December 2024. Available online: https://focus.world-exchanges.org/issue/december-2024/market-statistics (accessed on 7 January 2025).
- TLSNotary. n.d. TLSNotary: A Mechanism for Independently Audited HTTPS Sessions. TLSNotary. 1. Available online: https://tlsnotary.org/TLSNotary.pdf (accessed on 22 November 2023).
- Tripathi, Bhaskar, and Rakesh Kumar Sharma. 2022. Modeling bitcoin prices using signal processing methods, bayesian optimization, and Deep Neural Networks. Computational Economics 62: 1919–45. [Google Scholar] [CrossRef]
- Vancea, Diane Paula Corina, Kamer Ainur Aivaz, and Cristina Duhnea. 2017. Political Uncertainty and Volatility on the Financial Markets—the Case of Romania. Transformations in Business and Economics 16: 2A. [Google Scholar]
- Wagner, Michel, Nicolai Krüger, Markus Kleffmann, and Frank Teuteberg. 2024. Decentralized Finance: Development of A Taxonomy to Support Regulatory Measures. IU Discussion Papers—IT & Engineering. Available online: https://www.econstor.eu/bitstream/10419/300862/1/1898217947.pdf (accessed on 13 January 2025).
- Wang, Haiyao, Jianxuan Wang, Lihui Cao, Yifan Li, Qiuhong Sun, and Jingyang Wang. 2021. A Stock Closing Price Prediction Model Based on CNN-BiSLSTM. Complexity 2021: 5360828. [Google Scholar] [CrossRef]
- Wątorek, Marcin, Jarosław Kwapień, and Stanisław Drożdż. 2023. Cryptocurrencies Are Becoming Part of the World Global Financial Market. Entropy 25: 377. [Google Scholar] [CrossRef]
- Wronka, Christoph. 2023. Financial crime in the decentralized finance ecosystem: New challenges for compliance. Journal of Financial Crime 30: 97–113. [Google Scholar] [CrossRef]
- Wu, Jingyang, Xinyi Zhang, Fangyixuan Huang, Haochen Zhou, and Rohtiash Chandra. 2024. Review of deep learning models for crypto price prediction: Implementation and evaluation. arXiv arXiv:2405.08089v1. [Google Scholar]
- Zhao, Haidong, and Lini Zhang. 2021. Financial Literacy or investment experience: Which is more influential in cryptocurrency investment? International Journal of Bank Marketing 39: 1208–26. [Google Scholar] [CrossRef]
- Zheng, Peilin, Zigui Jiang, Jiajing Wu, and Zibin Zheng. 2023. Blockchain-Based Decentralised Application: A Survey. IEEE Open Journal of the Computer Society 4: 121–33. [Google Scholar] [CrossRef]
No. | Strategy | Description |
---|---|---|
1 | ±USD 50 price change | Buy or sell BTC when there is a ±USD 50 change between the Bitcoin open and the predicted Bitcoin close price with 0.5% fees taken from each trade. |
2 | Moving average convergence or divergence (MACD) crossover with ±USD 50 price change | Buy or sell when the MACD line crosses over or under the signal line, together with the ±USD 50 price change strategy criteria. |
3 | MACD ratio with ±USD 50 price change | Buy or sell BTC when the MACD ratio is above 1.25 or below 0.75, together with the ±USD 50 price change strategy criteria. |
Service | Framework | Libraries | Host Provider |
---|---|---|---|
Web | React | Ether.js, Uniswap SDK, Web3Auth, Firebase, Tailwind CSS | Firebase Hosting |
Scheduler | Node.js | Ether.js, Uniswap SDK, Firebase | Firebase Function |
Oracle | Node.js | Ether.js, Uniswap SDK, Firebase, Replicate | Firebase Function |
Smart Contract | Solidity | Uniswap, Ether.js Openzeppelin, Hardhat | Arbitrum Blockchain |
ML Model Development | Python | Numpy, Pandas, Scikit-learn, Matplotlib, Seaborn, Tensor-flow | - |
ML Model | Cog | Numpy, Pandas, Scikit-learn, Tensor-flow | Replicate |
Database | Firestore | - | Firebase |
Feature | Source |
---|---|
Bitcoin open price | Yahoo Finance |
Bitcoin close price | Yahoo Finance |
Bitcoin total Fees, USD | Coin Metrics 1 |
Bitcoin supply held by all mining entities, USD | Coin Metrics 1 |
Bitcoin miner revenue, USD | Coin Metrics 1 |
Bitcoin difficulty, last | Coin Metrics 1 |
Bitcoin hash rate, mean | Coin Metrics 1 |
Bitcoin revenue per hash unit, USD | Coin Metrics 1 |
Bitcoin mean block size, bytes | Coin Metrics 1 |
Bitcoin MVRV capitalization, free float | Coin Metrics 1 |
Bitcoin flow into exchanges, USD | Coin Metrics 1 |
Bitcoin flow out of exchanges, USD | Coin Metrics 1 |
Ethereum open price | Yahoo Finance |
Solana open price | Yahoo Finance |
Cardano open price | Yahoo Finance |
Binance Coin open price | Yahoo Finance |
Doge Coin open price | Yahoo Finance |
Polygon open price | Yahoo Finance |
Market capitalization | CoinMarketCap |
Gold open price | Yahoo Finance |
Silver open price | Yahoo Finance |
Oil open price | Yahoo Finance |
U.S Dollar Index open price | Yahoo Finance |
10-year yield open price | Yahoo Finance |
S&P 500 open price | Yahoo Finance |
DJI open price | Yahoo Finance |
Nasdaq open price | Yahoo Finance |
Nikkei 225 open price | Yahoo Finance |
CSI 3000 open price | Yahoo Finance |
Bitcoin fear/greed index | Alternative.me |
Metric | Description | Formula |
---|---|---|
MAE | Measures the average absolute difference between the predicted and actual Bitcoin prices. | |
RMSE | Provides an interpretable measure of the average magnitude of the prediction errors in the same unit as the target variable, helping to understand the average prediction error. | |
MAPE | Measures the average absolute percentage difference between the predicted and actual Bitcoin prices. |
Model | RF | LSTM | Bi-LSTM |
---|---|---|---|
MAE | 1417.32 | 1418.14 | 1074.49 |
RMSE | 2304.62 | 2160.36 | 1500.82 |
MAPE | 0.0335 | 0.0335 | 0.0280 |
Date | RF | LSTM | Bi-LSTM | MACD (RATIO) RF | MACD (RATIO) LSTM | MACD (RATIO) Bi-LSTM | MACD (CROSS) RF | MACD (CROSS) LSTM | MACD (CROSS) Bi-LSTM | Buy and Hold |
---|---|---|---|---|---|---|---|---|---|---|
1 January 2023 | $0.00 | −$44.85 | −$44.85 | $0.00 | $1.06 | $1.06 | $0.00 | −$27.19 | −$27.19 | −$44.85 |
1 February 2023 | $171.96 | $397.82 | $404.56 | $244.75 | $428.50 | $428.50 | $0.00 | $388.19 | $388.19 | $362.98 |
1 March 2023 | $171.96 | $485.82 | $583.66 | $144.81 | $416.34 | $463.64 | $0.00 | $357.55 | $357.55 | $358.55 |
1 April 2023 | $248.15 | $919.94 | $1109.16 | $159.62 | $756.99 | $815.66 | $0.00 | $357.55 | $357.55 | $632.28 |
1 May 2023 | $289.98 | $1250.56 | $1177.13 | $146.58 | $746.98 | $795.25 | $0.00 | $357.55 | $248.87 | $613.92 |
1 June 2023 | $64.08 | $1152.81 | $1078.58 | $94.68 | $730.34 | $713.98 | $0.00 | $341.44 | $192.33 | $540.87 |
1 July 2023 | $189.11 | $1480.25 | $1367.63 | $248.56 | $973.58 | $900.62 | −$42.25 | $530.01 | $359.94 | $757.47 |
1 August 2023 | $198.26 | $1406.12 | $1296.86 | $211.24 | $914.59 | $843.81 | −$42.25 | $484.28 | $319.29 | $704.94 |
1 September 2023 | −$4.02 | $1231.53 | $1130.20 | $53.08 | $664.59 | $603.05 | −$178.14 | $322.46 | $175.46 | $482.31 |
1 October 2023 | $3.41 | $1420.34 | $1310.44 | $83.00 | $805.43 | $738.68 | −$108.60 | $434.35 | $274.92 | $607.73 |
1 November 2023 | $161.40 | $2071.36 | $1741.86 | $271.35 | $1286.31 | $1201.78 | $128.82 | $816.4 | $614.49 | $1035.95 |
1 December 2023 | $130.07 | $2353.17 | $2007.41 | $388.00 | $1496.08 | $1403.81 | $81.04 | $983.06 | $762.63 | $1222.75 |
1 January 2024 | $226.38 | $2828.00 | $2433.28 | $510.09 | $1849.54 | $1744.20 | $124.38 | $1263.87 | $1012.23 | $1537.51 |
1 February 2024 | $284.72 | $2733.39 | $2348.43 | $638.08 | $1779.12 | $1676.38 | $124.38 | $1207.92 | $962.5 | $1474.80 |
1 March 2024 | $336.43 | $4411.75 | $3853.73 | $655.48 | $3028.48 | $2879.56 | $124.38 | $2200.5 | $1844.75 | $2587.35 |
1 April 2024 | $336.23 | $5041.11 | $4418.19 | $641.95 | $3496.97 | $3330.73 | $124.38 | $2572.7 | $2175.57 | $3004.54 |
1 May 2024 | $336.23 | $4048.89 | $3896.94 | $641.95 | $2758.37 | $2619.43 | $124.38 | $1985.91 | $1654.01 | $2346.82 |
23 May 2024 | $336.23 | $4887.48 | $4679.07 | $641.95 | $3382.61 | $3220.59 | $124.38 | $2481.85 | $2094.82 | $2902.70 |
Metric | RF | LSTM | Bi-LSTM | MACD (RATIO) RF | MACD (RATIO) LSTM | MACD (RATIO) Bi-LSTM | MACD (CROSS) RF | MACD (CROSS) LSTM | MACD (RATIO) Bi-LSTM | Buy and Hold |
---|---|---|---|---|---|---|---|---|---|---|
Initial Capital | $1000 | $1000 | $1000 | $1000 | $1000 | $1000 | $1000 | $1000 | $1000 | $1000 |
Win Trade | 24 | 34 | 31 | 6 | 5 | 4 | 2 | 2 | 1 | - |
Loss Trade | 30 | 11 | 16 | 6 | 2 | 3 | 6 | 3 | 4 | - |
Total Trade | 54 | 45 | 47 | 12 | 7 | 7 | 8 | 5 | 5 | - |
Win Ratio | 0.44 | 0.75 | 0.65 | 0.5 | 0.71 | 0.57 | 0.25 | 0.4 | 0.2 | - |
Loss Ratio | 0.55 | 0.24 | 0.34 | 0.5 | 0.28 | 0.42 | 0.75 | 0.6 | 0.8 | - |
Win–Loss Ratio | 0.8 | 3.09 | 1.93 | 1.0 | 2.5 | 1.3 | 0.33 | 0.66 | 0.25 | - |
Total Profit | $336.23 | $4887.47 | $4679.06 | $641.94 | $3382.61 | $3220.59 | $124.38 | $2481.85 | $2094.82 | $2346.82 |
ROI | 33.62% | 488.74% | 467.90% | 64.19% | 338.26% | 332.05% | 12.43% | 248.18% | 209.48% | 234.68% |
Peak Value | $1356.23 | $6334.16 | $5946.18 | $1937.65 | $4715.12 | $4540.81 | $1197.54 | $3746.02 | 3329.62 | $4198.80 |
Trough Value | $959.41 | $944.49 | $944.49 | $1000 | $996.39 | $996.39 | $801.53 | $968.27 | $968.26 | $944.49 |
Maximum Drawdown | −29.25% | −85.08% | −84.11% | −48.39% | −78.86% | −78.05% | −33.06% | −74.15% | −70.92% | −77.70% |
Sharpe Ratio (0.223%) | 1.58 | 1.32 | 1.38 | 1.24 | 1.30 | 1.32 | 0.24 | 1.13 | 1.06 | 1.22 |
Model | Timeframe | RMSE | MAE | MAPE |
---|---|---|---|---|
RF of our system | 1 Day | 2304.62 | 1417.32 | 0.0335 |
LSTM of our system | 1 Day | 2160.36 | 1418.14 | 0.0335 |
Bi-LSTM of our system | 1 Day | 1500.82 | 1074.49 | 0.0280 |
RF (Chen 2023) | 1 Day | 2096.24 | - | 0.0329 |
Bi-LSTM (Seabe et al. 2023) | 1 Day | 1029.36 | - | 0.0356 |
DANN (Tripathi and Sharma 2022) | 1 Day | 288.59 | 181.72 | 0.0225 |
1DCNN-GRU (Kang et al. 2022) | 1 Minute | 43.93 | - | - |
Model (Strategy) | Timeframe | Win Trade Ratio | ROI After Fees |
---|---|---|---|
RF of our system | 1 Day | 0.44 | 33.62% |
LSTM of our system | 1 Day | 0.75 | 488.74% |
Bi-LSTM of our system | 1 Day | 0.65 | 467.90% |
MACD (RATIO) RF | 1 Day | 0.5 | 64.19% |
MACD (RATIO) LSTM | 1 Day | 0.71 | 338.26% |
MACD (RATIO) Bi-LSTM | 1 Day | 0.57 | 332.05% |
MACD (CROSS) RF | 1 Day | 0.25 | 12.43% |
MACD (CROSS) LSTM | 1 Day | 0.4 | 248.18% |
MACD (CROSS) Bi-LSTM | 1 Day | 0.2 | 209.48% |
RF (Chen 2023) | 1 Day | 0.5 | 1.24% |
Multi-layered Neural Network (Parente et al. 2024) | 4 h | 0.66 | 11% |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2025 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Lua, Z.Z.; Seow, C.K.; Chan, R.C.B.; Cai, Y.; Cao, Q. Automated Bitcoin Trading dApp Using Price Prediction from a Deep Learning Model. Risks 2025, 13, 17. https://doi.org/10.3390/risks13010017
Lua ZZ, Seow CK, Chan RCB, Cai Y, Cao Q. Automated Bitcoin Trading dApp Using Price Prediction from a Deep Learning Model. Risks. 2025; 13(1):17. https://doi.org/10.3390/risks13010017
Chicago/Turabian StyleLua, Zhi Zhan, Chee Kiat Seow, Raymond Ching Bon Chan, Yiyu Cai, and Qi Cao. 2025. "Automated Bitcoin Trading dApp Using Price Prediction from a Deep Learning Model" Risks 13, no. 1: 17. https://doi.org/10.3390/risks13010017
APA StyleLua, Z. Z., Seow, C. K., Chan, R. C. B., Cai, Y., & Cao, Q. (2025). Automated Bitcoin Trading dApp Using Price Prediction from a Deep Learning Model. Risks, 13(1), 17. https://doi.org/10.3390/risks13010017