Educational Reference

Backtesting Trading Strategies on Indian Markets: Why 95% of Retail Backtests Are Useless

Indian retail trading platforms now bundle 'backtesting' tools that produce a Sharpe ratio in 5 seconds. 95% of these backtests are statistically meaningless — the math behind them ignores look-ahead bias, survivorship bias, transaction costs, and multiple-testing correction. The Bharath Shiksha Stage 4 (Mastery I — Quantitative Edge) curriculum covers what institutional backtesting actually requires. This page is the educational primer.

What 'backtesting' usually means in retail tools

Most retail backtesting tools (Streak, Tradetron, Sensibull simulators) take a strategy definition + historical price data + apply the strategy bar-by-bar to compute a hypothetical equity curve. Output: Sharpe ratio, drawdown, win rate. This is fine as a sanity check; it is not statistical validation. The output ignores: (1) look-ahead bias (using data not available at decision time); (2) survivorship bias (testing on stocks that exist today, ignoring delistings); (3) transaction costs (most retail tools assume zero slippage and zero commission); (4) multiple testing (running 100 variants and reporting the best). Each of these can inflate apparent edge by 30-100%.

Look-ahead bias: the most common error

Look-ahead bias occurs when a backtest uses information that wasn't available at the decision moment. Common cases: (1) using closing price for the entry signal but executing 'at close' — typically you can't execute at the actual close; (2) using next-day open with end-of-day signal but actually computing on adjusted-close that includes future dividends; (3) using fundamental data (e.g. quarterly earnings) at announcement-date timestamps when the data was actually published with a delay. Stage 4 Volume 2 (Backtesting Foundations) opens with this principle: every dataset must be lagged by its actual real-time-availability delay.

Indian-context costs that retail backtests ignore

Indian transaction costs stack: STT (Securities Transaction Tax) on every trade — 0.1% intraday, 0.025% delivery; Exchange transaction charges — NSE 0.00325%, BSE varies; SEBI turnover — 0.0001%; Stamp duty — 0.015% on buy side; GST on brokerage — 18% of the brokerage charge; DP charges — ₹13-15 per scrip on sell; Slippage — typically 0.05-0.20% on liquid stocks, more on illiquid. Total round-trip cost on a typical equity trade: 0.30-0.60%. A strategy with 0.5% per-trade edge at zero-cost backtest may have zero or negative edge after honest cost modeling. Stage 4 Volume 1 (Quant Research Workflow) covers FY26 Indian transaction-cost stack codified in code.

CPCV, Probabilistic Sharpe, Deflated Sharpe — institutional validation

Marcos López de Prado's 2018 work (Advances in Financial Machine Learning) introduced three institutional validation tools that retail almost never uses. (1) Combinatorial Purged Cross-Validation (CPCV) — k-fold CV adapted for time-series with leakage prevention. (2) Probabilistic Sharpe Ratio (PSR) — probability that observed Sharpe exceeds threshold given sample size. (3) Deflated Sharpe Ratio (DSR) — Sharpe corrected for multiple testing across N variants tested. A retail backtest reporting Sharpe 1.5 might have PSR 0.30 (only 30% chance the true Sharpe exceeds 0.5) — meaning the strategy probably has no edge. Stage 4 Volume 5 (Advanced Validation) covers all three with Python implementations.

The honest backtesting workflow

Bharath Shiksha Stage 4 sequence: (1) Define hypothesis in writing before any code; (2) Source clean data with corporate-action adjustments and survivorship-free universe; (3) Implement strategy with explicit lag on every signal; (4) Apply FY26 Indian cost stack to every trade; (5) Run on out-of-sample data the strategy has never seen during development; (6) Compute CPCV, PSR, DSR — not just point Sharpe; (7) Document the test in a versioned research log; (8) Walk-forward test on rolling out-of-sample windows; (9) Paper-trade for at least one quarter on live data before any capital deployment; (10) Deploy at fraction-of-Kelly position sizing on live capital. Most retail traders skip steps 4-9. Bharath Shiksha curriculum doesn't allow skipping any of them.

FAQ

Frequently asked questions

Why is backtesting on retail platforms unreliable?

Retail backtesting tools (Streak, Tradetron, brokerage simulators) typically ignore: look-ahead bias, transaction costs, survivorship bias, and multiple-testing correction. A strategy showing Sharpe 1.5 on retail backtest may have zero or negative edge after institutional validation. Bharath Shiksha Stage 4 (Quantitative Edge) covers the institutional framework that produces statistically defensible results.

What is the FY26 Indian transaction cost stack?

Total round-trip cost on a typical equity trade in FY26 India: STT (0.025% delivery, 0.10% intraday on sell side), Exchange charges (~0.003%), SEBI turnover (0.0001%), Stamp duty (0.015% buy side), GST (18% on brokerage), DP charges (₹13-15 per scrip on sell), Slippage (0.05-0.20%). Total: 0.30-0.60% per round-trip. Stage 4 Volume 1 codifies this in Python.

What's the difference between Sharpe and Deflated Sharpe?

Sharpe ratio = (return - risk-free) / volatility. It's a point estimate. Deflated Sharpe Ratio (DSR) corrects for multiple testing — if you tested 100 strategy variants and report the best, the apparent Sharpe is inflated. DSR computes the probability your reported Sharpe is real, given the number of trials. Marcos López de Prado, Advances in Financial Machine Learning. Stage 4 Volume 5 covers DSR with Python implementation.

How long should I backtest before going live?

Statistical guidelines: minimum 30+ years of bar data for reliable estimates (most retail strategies fail this). Minimum 1 year of out-of-sample data the strategy has never seen during development. Minimum 1 quarter of paper-trading on live data after backtest validation. After live capital deployment, start at quarter-Kelly position sizing for the first 6 months. Stage 4 Volume 5 covers the full validation timeline.

Should I use machine learning for trading strategies?

Maybe — but only after mastering classical statistical validation. Most retail ML applications to trading fail because the underlying validation is wrong, not because ML is wrong. Stage 4 Volume 4 covers ML for trading framed as cross-sectional ranking (the only ML framing that consistently produces edge in Indian markets). Tree-based models (XGBoost, LightGBM) with proper CPCV outperform deep learning for retail-scale capital.

Related

Continue reading

Next step

Find your starting stage. Everything else follows from there.

Educational reference only. No buy/sell/hold recommendations. Examples use 30-day data lag per SEBI Jan 2025 circular.