Model the Flows · Lesson 9 of 9

Backtests and Psychology

How backtests flatter you, the built-in limits of hypothetical results, and how to build a playbook judged by process rather than outcome.

7 min readAdvancedModule 2: Model Risk and JudgmentUpdated

In this lesson

  • Spot look-ahead bias, overfitting and survivorship bias in a backtest
  • Explain the built-in limits of hypothetical and simulated results
  • Build a written playbook from your own reviewed trades
  • Grade decisions by process, not by single outcomes

A backtest runs a set of rules over past data to see how they would have done. Done honestly, it kills bad ideas cheaply, before they cost real money. Done carelessly, it produces a beautiful equity curve that has nothing to do with the future. The difference comes down to what you let the test know, how many times you let it try, and what you assume about costs. Four traps account for most flattering backtests.

  1. Look-ahead bias

    Look-ahead bias means using information the rule couldn’t have had at the time. A positioning example: a rule that acts at 10 a.m. using levels built from open interest that settled that night. The real 10 a.m. map was built from the prior day’s open interest. Using the day’s close, high or low to time an earlier entry is the same mistake.

  2. Overfitting

    Overfitting happens when you tune settings until the rules fit the noise of the past. Every extra filter, threshold and time window you test adds another chance to find something that looks great by luck. The best of hundreds of variations nearly always looks impressive. The main defense is an out-of-sample test: tune on one stretch of data, then run the rules, unchanged, on a later stretch you never looked at. If you peek at those results and retune, that later stretch stops being out of sample, and you need fresh data to test again.

  3. Survivorship bias

    Survivorship bias creeps in when you test only on what exists today, such as current index members, and skip the stocks that were delisted or merged away. A test of today’s S&P 500 members over the past twenty years quietly leaves out the companies that failed or shrank out of the index along the way. The same thing happens when you study only the traders still around to share their results.

  4. Costs and fills

    Many backtests assume fills at the midpoint with no slippage. Real trades pay the bid-ask spread, commissions and fees, and fast markets fill worse. On short-dated options, those costs can erase a small edge: an option quoted $0.90 bid and $1.00 ask costs about $5 per contract more than the midpoint on the way in and $5 on the way out, so 200 round trips carry about $2,000 in spread costs alone, which a midpoint backtest never pays.

Example Consider this example

Imagine 100 rules tested on pure coin flips, 40 trades each. Every rule truly wins 50% of the time. Just by chance, the best of the 100 usually shows about 28 wins out of 40: a 70% win rate. Run that “winner” on new coin flips and it goes back to winning about half the time, before costs. Nothing about the rule changed; the earlier result was luck that the selection process picked out.

Overfitting Game

A simulated price series made of pure random noise, with a rule whose settings you can adjust. As you tune, the in-sample equity curve climbs more smoothly and its win rate rises. Pressing “run on new data” applies the same settings to fresh random data, where the curve flattens and drifts slightly down after simulated costs, showing that the earlier fit had captured noise.

Overfitting Game: tune a rule on past random data until it looks perfect, then run it on data it hasn’t seen. Illustrative, simulated data. Simulated — not actual trading

Watch out Simulated results have built-in limits

Backtests, paper trades and simulators all produce hypothetical results, and those have limits no amount of care removes. They’re designed with the benefit of hindsight. They aren’t actual trading, so they may not reflect real fills, spreads or liquidity. No real money is at risk, so they can’t capture what losses do to judgment, and the ability to keep following a plan through a losing streak shapes real results. No hypothetical record shows that any account will, or is likely to, earn similar results, and real results often differ sharply. That’s why simulated results should always be labeled as simulated, and why the SEC places strict conditions on investment advisers who advertise hypothetical performance.

Process over outcome

The hardest part of trading is often the trader. Research on loss aversion suggests a loss tends to feel roughly twice as strong as a gain of the same size. That pull shows up as cutting winners early to lock in the good feeling, holding losers in the hope they come back, and moving an invalidation “just this once.” A written process is how you protect decisions from those moments: you judge each trade by whether you followed the plan, and you judge the plan itself only over many trades.

Grade the process

  • Did I act only on my written trigger?
  • Did I respect my invalidation, at the size my plan set?
  • Would I make the same decision again with the same information?
  • Was my confidence about right? Tracking it over many trades shows your calibration.

Not the single outcome

  • A good process can lose; that’s the normal cost of a plan with positive expectancy.
  • A broken process that wins is luck, and it’s the most dangerous lesson, because it rewards the mistake.
  • A plan that truly wins half the time shows 60% or better over 20 trades about a quarter of the time, so a small sample size can’t separate skill from luck.
  • After a loss, the urge to win it back fast is revenge trading. Change the plan in reviews, not mid-trade.

Build a playbook from your journal

  1. Describe one setup in plain words

    Name conditions you can observe, such as “Calm regime, price testing the Ceiling zone, Build-up rising.” A playbook entry describes a situation you’ve studied. It isn’t a promise about what price will do.

  2. Write the rules before the results

    Fix the trigger, invalidation, size and exit on paper first, so the results can’t shape the rules. It’s look-ahead protection for your own head.

  3. Collect every example

    Log each time the setup appears in your trading journal, including the ones you skipped or missed, so you aren’t studying only the winners.

  4. Review in batches

    Judge the setup after dozens of examples, not after each trade. Look at expectancy, drawdown and how often you followed the rules. Guard against confirmation bias by counting the examples that went against you as carefully as the ones that worked.

  5. Change one thing at a time

    Test each change on new examples, not the ones you tuned it on. Retire setups that stop working instead of adding filters until the past looks perfect.

Check your understanding

5 questions. Answer each one, then open “Show answer” to compare.

  1. Question 1 of 5 A backtest buys at 10 a.m. whenever price is below the day’s Floor, and that Floor is computed from open interest that settled that evening. What’s the main problem?
    Show answer

    Answer: A. Look-ahead bias: at 10 a.m. that open interest didn’t exist yet

    Open interest settles overnight, so a real 10 a.m. map was built from the prior day’s open interest. A test that uses that evening’s numbers is peeking at information the rule couldn’t have had.

  2. Question 2 of 5 If the best of 200 rule variations made money on past data, that’s strong evidence it will work on new data.
    Show answer

    Answer: False.

    Testing many variations nearly always finds some that fit the noise. The honest check is out of sample: run the chosen rule, unchanged, on data that played no part in choosing it.

  3. Question 3 of 5 Your journal shows a setup with a 45% win rate, an average win of $180 and an average loss of $100 over 40 trades. What’s its expectancy per trade, before costs?

    $
    Show answer

    Answer: 26 $ (anything within ±0.5 $ counts).

    0.45 × $180 − 0.55 × $100 = $81 − $55 = $26 per trade. Forty trades is still a small sample, and costs come off the top, so treat it as a starting estimate.

  4. Question 4 of 5 You ignored your written invalidation, held a losing trade, and it came back for a $300 gain. How should a process review grade it?
    Show answer

    Answer: A. As a process mistake: the result was good, but the decision broke the plan and risked a larger loss

    The outcome was luck layered on a broken process. Grading it as a success teaches you to skip invalidations, which is how small losses turn into large ones.

  5. Question 5 of 5 Which of these are built-in limits of hypothetical or simulated results? Select all that apply. Select all that apply.
    Show answer

    Answers: A. They’re designed with the benefit of hindsight · B. They may not reflect real fills, spreads or liquidity · C. They can’t capture the pressure of risking real money

    Hindsight, idealized fills and the missing pressure of real losses all separate simulated results from real ones. That’s why no hypothetical record shows what a real account would have earned.

Key takeaways

  • Backtests describe the past under assumptions; look-ahead bias, overfitting and survivorship bias make them look better than reality.
  • Simulated and hypothetical results have built-in limits and don’t show what any real account will earn.
  • Build a playbook from your own reviewed trades: rules written first, judged over dozens of examples, changed one thing at a time.
  • Grade decisions by process; a good result from a broken plan is still a mistake.

Try it in StratosHedge

Open Replay for a recorded SPY session. Write your plan for the first hour before you watch what happened next, then grade the plan, not the result.

Practice the process in Replay Needs: Retail plan

Key terms

Backtest
Testing a set of trading rules on past data to see how they would have performed. The results are hypothetical and describe the past.
Look-ahead bias
Using information in a backtest that wouldn’t have been available at the time, such as the day’s close or tomorrow’s open interest.
Overfitting
Tuning rules so closely to past data that they capture noise instead of a real pattern. Overfit rules look great in a backtest and fail on new data.
Survivorship bias
Studying only what survived, such as stocks still listed today or traders still in business, which makes results look better than reality.
Bid-ask spread
The gap between the bid and the ask. It’s a cost you pay every time you enter and exit a trade.
Calibration
How well your confidence matches reality. If the things you call 70% likely happen about 70% of the time, you’re well calibrated.
Expectancy
The average a set of trades makes or loses per trade over many trades: win rate × average win minus loss rate × average loss.
Sample size
How many trades or observations a result rests on. Ten trades can’t separate skill from luck; results usually need dozens to hundreds.
Revenge trading
Taking impulsive, often larger trades to win back a recent loss. It abandons the plan right when judgment is weakest.
Trading journal
A record of each trade’s plan, entry, exit, result and what you were thinking. Reviewing it reveals patterns no single trade can show.
Confirmation bias
Noticing evidence that supports what you already believe and discounting what doesn’t. It makes traders hold on to broken ideas too long.

Sources and further reading

Educational content, not investment advice. Lessons describe how markets and models tend to behave. They don’t tell anyone what to buy, sell or hold. Interactive examples use illustrative sample data, and simulator results are simulated — not actual trading. Options involve risk and are not suitable for all investors.

Our purpose. Your perspective.

Data intelligence.
Visualization with context.

StratosHedge is a data intelligence company focused on organizing and visualizing market information. Our charts, analytics, estimates, alerts, and educational content are provided for informational and educational purposes only. They are not financial, investment, tax, or legal advice, or recommendations to buy, sell, or hold any security.

Investing involves risk. Investing in stocks can result in the loss of some or all money invested. Options involve substantial risk: buyers can lose the entire premium paid, and certain strategies can produce losses greater than the initial investment. Uncovered call writing can expose investors to potentially unlimited losses.

Market data and model estimates may be delayed, incomplete, or inaccurate. You are responsible for your investment decisions.

Read our policies and risk disclosures