Introduction
The cryptocurrency market, particularly Bitcoin, has experienced a surge in interest among individuals and institutions due to its rapid growth, high volatility, and 24/7 availability. However, the inherent price fluctuations pose substantial risks, necessitating advanced trading strategies.
Machine learning (ML) algorithms have found wide applicability in financial world problems, including trading. Researchers have focused on predicting future asset prices, such as stocks or Bitcoin. Sentiment analysis on social media platforms, especially Twitter, has also been explored for its potential to influence market trends and Bitcoin prices.
Related Work
A comprehensive review of related works is provided, highlighting the extensive body of literature on developing effective trading strategies. It also discusses studies that employ Bitcoin historical price data and research on developing trading decisions with a focus on Twitter sentiment data.
Several studies have investigated the effectiveness of Twitter sentiment analysis in formulating effective trading strategies, suggesting that public opinion expressed on social media significantly influences market trends and Bitcoin prices.
Data Preparation
The data preparation process involves gathering and preprocessing Bitcoin historical price data and Twitter sentiment data. The Bitcoin historical price data is sourced from a crypto platform, spanning from October 1, 2014 to March 1, 2019. Twitter sentiment data is collected from April 1, 2014, to November 14, 2018, using Twitter’s streaming API and targeting relevant keywords.
To enhance the transparency and reproducibility of the approach, detailed insights into the data preparation stage are provided.
Multi-Level DQN
The proposed trading strategy is based on a multi-level DQN (M-DQN) model, which consists of three DQN-based modules: Trade-DQN, Predictive-DQN, and Main-DQN.
Trade-DQN generates initial trading recommendations based solely on Bitcoin historical price data. Predictive-DQN is used to obtain future Bitcoin price predictions based on Bitcoin-related tweet sentiment scores and historical price information.
Main-DQN explores the synergistic effects of integrating the outputs of the previous two DQN models and examines a combination of these data sources for improved decision-making and trading performance.
A novel reward function is proposed that considers three important aspects of successful trading: profit maximization, risk minimization, and maintaining active trading.
The M-DQN structure facilitates a more granular approach to learning and decision-making. By compartmentalizing the learning process, each module can specialize and become more efficient in its respective domain. This specialization leads to enhanced performance in each task—be it price prediction, sentiment analysis, or trade recommendation.
Experiment and Results
Extensive experiments are conducted to evaluate the performance of the proposed M-DQN model. The dataset is split into two parts: one for training and the other for testing. The M-DQN model is trained using a deep neural network architecture and a set of hyperparameters fine-tuned to optimize the trading strategy.
The experimental results demonstrate the effectiveness of the M-DQN model in optimizing Bitcoin trading strategy, considering various factors such as risk, return, and active trading. The proposed reward function outperforms two existing reward functions from the literature, highlighting its efficiency in balancing the aforementioned factors.
The M-DQN model consistently achieves higher ROI and SR values compared to the classical method, further emphasizing the advantages of the proposed preprocessing technique and reward function.
Discussion
The study demonstrates the effectiveness of the M-DQN model in developing an enhanced Bitcoin trading strategy. However, certain limitations are acknowledged, including the reliance on a single cryptocurrency platform and the potential for further improvements in the reward function.
Future research directions are proposed, such as exploring diverse ML models, incorporating real-world trading problems into the reward function, and expanding the scope of data to include multiple cryptocurrency platforms.
Conclusion
The M-DQN model offers a robust and effective approach for Bitcoin trading. By integrating market-action data and Twitter sentiment scores, the model captures valuable insights and generates profitable trading strategies. The study contributes to the field of cryptocurrency trading by demonstrating the potential of integrating historical price data and sentiment analysis for enhanced decision-making.