Developing a Robust Market-Neutral Pairs Trading Strategy for the NSE: An Analytical Case Study of Statistical Arbitrage in Indian Equities

The landscape of algorithmic trading in India has undergone a significant transformation over the last decade, as retail and institutional investors increasingly turn to data-driven strategies to navigate the volatility of the National Stock Exchange (NSE). Among these methodologies, statistical arbitrage—specifically pairs trading—has emerged as a cornerstone for market-neutral investing. A recent comprehensive study conducted by financial analyst Shant Tandon provides a rigorous, academic-grade evaluation of this strategy, covering the period from January 2015 to June 2025. By employing a walk-forward testing framework, the research sheds light on the challenges and potential of executing mean-reversion strategies within the Indian large-cap ecosystem.
Understanding the Mechanics of Statistical Arbitrage
Pairs trading is fundamentally a relative-value strategy that operates on the premise of cointegration. Two assets, historically linked by business operations, industry correlation, or macroeconomic factors, are expected to maintain a stable long-term relationship. When the price spread between these two assets diverges beyond a statistically significant threshold, the trader shorts the outperforming asset and buys the underperforming one, betting that the relationship will revert to its historical mean.
In this specific project, Tandon focused on 25 NSE large-cap stocks across critical sectors, including Banking, IT, Pharmaceuticals, Cement, and Auto. The selection process was far from arbitrary; it utilized the Augmented Dickey-Fuller (ADF) test to ensure the residuals of the spread were stationary. To combat the pervasive issue of "data mining bias"—where a strategy appears profitable only because it was tested against too many variables—the study employed the Benjamini-Hochberg False Discovery Rate (FDR) at a 5% significance level. This statistical rigour is essential for any institutional-grade algorithmic framework, as it ensures that the selected pairs possess genuine cointegration rather than merely random correlations.
Chronology and Methodology: The Walk-Forward Approach
The strategy was backtested over a decade, utilizing a sophisticated walk-forward methodology. This approach is critical in quantitative finance to prevent look-ahead bias, a common pitfall where a model inadvertently uses future information to inform current decisions. The research employed a 252-trading-day rolling training window, followed by a 21-day out-of-sample test step.

The three primary pairs identified through this rigorous screening process were HDFCBANK.NS vs. KOTAKBANK.NS, HEROMOTOCO.NS vs. ULTRACEMCO.NS, and HCLTECH.NS vs. ICICIBANK.NS. These pairs demonstrate the cross-sectoral nature of the strategy, leveraging the interconnectedness of India’s banking and industrial engines. By shifting the rolling variables (mean and standard deviation) by one day, the strategy ensured that all trading signals were generated solely on the basis of information available at the time of execution.
Performance Metrics and Quantitative Analysis
The results of the backtest reveal the inherent difficulty of capturing alpha through pure mean-reversion in a market characterized by both structural shifts and intermittent volatility. Over the period of January 2016 to June 2025, the strategy executed 271 trades with a capital base of ₹15,00,000.
The portfolio achieved a win ratio of 63.47%, which is statistically impressive for a neutral strategy. However, the total Profit and Loss (PnL) of ₹1,65,544.97, representing a 11.04% return on capital, must be viewed in the context of the high annualized volatility of 13.34%. With an annualized return of 0.30% and a Sharpe ratio of 0.089, the strategy highlights the "volatility tax" that algorithmic traders often face. Most notably, the maximum drawdown of -34.31% serves as a stark reminder that even statistically sound pairs can diverge significantly during black-swan events or regime shifts, such as the 2020 market crash or subsequent inflationary cycles.
The Problem of Survivorship Bias and Structural Risks
One of the most critical aspects of Tandon’s analysis is his candid assessment of the strategy’s limitations. He identifies survivorship bias as a potential contributor to the historical performance metrics. By utilizing a fixed list of 25 stocks, the study inadvertently omits companies that may have been delisted or performed poorly during the ten-year period. In a real-world setting, a "point-in-time" universe—where the basket of stocks is updated to reflect the actual index composition of the NSE at any given moment—is essential to eliminate this bias.
Furthermore, the static nature of the entry and exit thresholds (z-score of ±1.5) proved insufficient during periods of extreme market stress. While these thresholds work well in stable, range-bound environments, they often fail during directional trends or market "melt-ups," leading to the significant drawdowns observed in the backtest.

Pathways to Institutional-Grade Refinement
To transition from a prototype to a deployable institutional strategy, several enhancements have been proposed. These improvements represent the current frontier of quantitative research for the Indian markets:
- Information-Criterion Based Selection: Moving beyond the basic ADF test to incorporate Akaike Information Criterion (AIC) or Bayesian Information Criterion (BIC) lag selectors will significantly improve the quality of pair selection.
- Dynamic Volatility Scaling: Rather than equal capital allocation, adopting a Kelly-criterion or inverse-volatility approach would allow the model to reduce exposure during high-volatility regimes and maximize capital efficiency during stable periods.
- Adaptive Thresholding: Implementing a regime-detection model—which adjusts entry/exit z-scores based on current market volatility—would allow the strategy to remain dormant during periods of high uncertainty and active during high-probability mean-reversion phases.
- Hard Stop-Loss Implementation: The absence of a hard stop-loss was a contributing factor to the -34.31% drawdown. Incorporating a risk-parity-based stop-loss, where a position is liquidated if the spread deviates beyond a specific threshold (e.g., z-score of ±3.0), is a non-negotiable requirement for capital preservation.
Broader Implications for the Indian Algorithmic Trading Ecosystem
The findings from this project underscore a vital truth in financial engineering: the "cleanest" academic strategy is often exposed to the harsh realities of market microstructure and liquidity constraints. As the NSE continues to mature, the barriers to entry for sophisticated strategies are lowering, but the bar for performance is rising.
The shift toward algorithmic trading in India is not merely a trend but a fundamental change in market participation. As more participants adopt statistical arbitrage, the "alpha" associated with simple cointegration signals is likely to be competed away, forcing traders to look toward more advanced machine learning models and alternative data sources.
For the aspiring quant, the journey from building a basic pairs-trading model to deploying a multi-factor, regime-aware portfolio is a process of iterative learning. As Tandon’s project demonstrates, the value lies not just in the final PnL, but in the rigorous identification of failure points. By dissecting the methodology—from the application of the Benjamini-Hochberg FDR to the identification of look-ahead bias—the analyst provides a roadmap for those looking to survive and eventually thrive in the complex, high-stakes environment of modern Indian equity markets.
In conclusion, while the prototype provides a solid foundational understanding of statistical arbitrage, the path to sustainable, risk-adjusted returns lies in the integration of adaptive risk management and more robust, dynamic statistical models. As the financial community continues to bridge the gap between academic theory and practical execution, projects of this nature serve as essential benchmarks for the next generation of algorithmic traders.







