A backtest is only honest when the rule is fixed before the held back data is opened

A backtest is only honest when the rule is fixed before the held back data is openedDiagram with 6 boxes. Write the rule and its inputs in words before opening the data to Fix the data and the cutoff, using only what was known on each day; Fix the data and the cutoff, using only what was known on each day to Charge costs, STT, fees and slippage on every trade; Charge costs, STT, fees and slippage on every trade to Count every variant tried, not only the one that worked; Count every variant tried, not only the one that worked to Run the held back period once and log the result; Run the held back period once and log the result to Any change after this point is a new test.Write the rule and its inputsin words before opening thedataFix the data and the cutoff,using only what was known oneach dayCharge costs, STT, fees andslippage on every tradeCount every variant tried,not only the one that workedRun the held back period onceand log the resultAny change after this pointis a new test
The order of a test that can be checked. A map of method, not a result. Source: RupeeCase method map; cost rules from NSE and SEBI. As of 16 Oct 2026.

A backtest is a question asked of past data. Overfitting happens when the answer is shaped by the question, through trying many rules, parameters or periods until one looks good. Each extra choice is another chance for a lucky result to pass as skill.

Look ahead bias is information used before it existed: a close price used to fill an order at that same close, a constituent list taken from today, or a revised number used as if it had been known on the day. Survivorship bias keeps only the stocks or contracts that lasted, so the losers that left the sample are missing from the test.

Data snooping is the quiet cousin. Test forty ideas and a couple will look significant by chance alone. The honest fix is to count every idea tested, not only the one that worked, and to hold back a period that no test has touched.

The flow below is the order of a test that can be checked. Each stage answers one question before the next one starts, and any change made after the held back period is a new test, not a revision of the old one.

Costs matter for the same reason. A rule that works before brokerage, STT, fees and slippage can fail once they are charged, and a backtest that leaves them out has not tested the strategy that would be traded.

Before you trade. Derivatives trading carries a high risk of loss. SEBI's study "Profitability of Individual Traders in the Equity Derivatives Segment (FY25 to FY26)" (August 2026) found that 87.7% of individual traders in equity F&O made net losses in FY26, with aggregate net losses of Rs 91,685 crore. Read the SEBI study