Leveraging Deep Reinforcement Learning for Real-Time Trading in Emerging Markets: Insights from NIFTY50
Abstract
Stock trading is a complex decision-making problem influenced by market volatility, macroeconomic conditions, and investor sentiment. Traditional strategies, such as technical analysis and statistical models, rely on predefined rules and historical patterns but often struggle to adapt to dynamic markets. Reinforcement learning (RL) offers an adaptive approach by enabling trading agents to learn from past experiences and optimize decisions over time. This study applies Q-learning (QN), Deep Q-Network (DQN), and Double Deep Q-Network (DDQN) to intraday trading on NIFTY 50 stocks, evaluating performance based on total profit, risk-adjusted returns, and trade execution efficiency. The models were trained on four years of historical data and tested on one year to assess adaptability to real-world conditions. Results show that DDQN outperforms both QN and DQN, achieving the highest total profit (₹1,151,325), best Sharpe ratio (0.3450), lowest max drawdown (-1.12%), and highest trade accuracy (67.72%). DQN improves over QN but suffers from higher drawdowns due to Q-value overestimation, while QN struggles with profitability and risk control. These findings confirm that RL-based trading models can significantly enhance decision-making and profitability in algorithmic trading.