Skip to content
Free beta

STAGE 03 · First Officer · C07

Manual Backtesting Step by Step

Strategy Testing and Uncertainty · Chapter C07.1

Risk-first learningIndependent practiceNo membership or sign-in required
Independent student audit copy. This is a new, ungraded extension lesson. The 90 existing core lessons and formal assessment rules are unchanged. Practice is interactive but not graded; instructor answers are not exposed.

First Officer · Strategy Testing and Uncertainty · About 30–40 minutes

Safety rule: Never use a later candle to justify a decision supposedly made earlier.

Your mission today

By the end you can run a chronological manual backtest and record every valid and rejected trade with costs.

Before you start

Finish C06.5. Choose a single demo symbol and a fixed set of rules. Use a replay tool or printed candles that hide the future.

1. A backtest asks what the rule would have done

A backtest applies a fixed trading rule to earlier market observations. Think of checking a fire-drill plan against old building layouts. It may reveal weaknesses, but it does not guarantee that tomorrow behaves like yesterday. A manual backtest means a person advances historical candles in order and records decisions without knowing the later outcome. Start with one exact instrument, its contract specification, a declared timeframe and a specific historical period. Write the entry, stop, exit, skip and cost rules before opening the replay. Include the time zone and chart data source. Survivorship bias can appear when you select only symbols or periods that remain attractive in hindsight. Avoid starting with a dramatic winning chart and working backward. Use an independently chosen chronological sample. A valid research log should include every setup offered by the rules, including the boring losers and correctly rejected candidates.

2. Calculate the proposed loss before simulating a result

Imagine a fictional EURUSD long that becomes eligible only after a completed M15 bar closes above 1.08500. The next executable Ask is assumed to be 1.08520; the planned Bid stop is 1.08420. That is 10 pips of price risk. At an invented $1 per pip, a stop fill at the intended level would lose −$10 before fees or worse execution. If a separately modelled round-trip commission costs $0.50, the result would become −$10.50. A later executable Bid of 1.08670 could instead give +15 pips, or +$14.50 net after the same commission, in a different imagined outcome. Neither result can be selected just because it looks nicer. Record which level was reached first under the simulation's stated execution assumptions. If both stop and target appear inside one candle and their order cannot be established, label the outcome AMBIGUOUS.

BLACK BOX JOURNEY · FOUR-PANEL VISUAL WORKSHOP

See it. Calculate it. Decide.

Four large teaching figures for C07.1. Use the calculation and decision panels alongside the worked example. All figures are synthetic; EURUSD quotes where shown are invented teaching examples, not market data or trade signals.

Backtest with the future hiddenA swing is confirmed only after required bars close1.084501.084001.083501.083001.08250010203040506070809101112CLASSROOM VIEWEURUSD · M15Not market data● Candle rise● Candle fallContext ≠ signalA profitable hindsight chart is not a valid chronological backtest.
Backtest with the future hidden · Original Black Box Journey visual, fully synthetic.
The decision sequenceSTEP 01Freeze ruleBefore moving on›STEP 02Advance barsBefore moving on›STEP 03Record every signalBefore moving on›STEP 04Add real costsDocument resultFreeze the rule before you look at the outcome.
The sequence of checks before committing to any decision · Original Black Box Journey visual, fully synthetic.
Show the units. Show the consequence.Buy 1.08520→Stop 1.08420: 10 pips→At $1/pip: −$10■
Worked arithmetic; figures are fictional and do not represent broker specifications · Original Black Box Journey visual, fully synthetic.
Two paths, two decisions✓ PROCESS DISCIPLINE✕ DANGEROUS SHORTCUTUse first knowable timeBackdate the signalRisk and evidence matter more than a lucky result. Educational example only.
Recognise the safe process and the misleading shortcut · Original Black Box Journey visual, fully synthetic.

3. Freeze the exact signal timestamp

A common error involves look-ahead bias, where information from the future affects a claimed past decision. Imagine a swing-high rule requiring two completed bars on the right of a candidate pivot. The pivot cannot be confirmed until both later bars close. A charting tool may draw its marker above the earlier pivot candle, but that visual position is not the time the information became available. Write the signal's first knowable timestamp, not merely the bar containing the extreme. Then advance one complete candle. Record whether the rule says TRADE, WAIT or SKIP at that time. Use the correct quote side. A Bid-candle close is not automatically the Ask available to buy. Record actual known spread if historical quotes exist; otherwise declare a justified cost assumption and test how sensitive results are to it.

4. Make an audit ledger that includes rejections

Use one line per offered setup, not just one line per placed trade. Include setup identifier, date, market, timeframe, eligible closing time, intended entry, stop, size, estimated cash loss, permitted or rejected status, reason, exit and total costs. A rejected setup is one that fails a prewritten criterion such as maximum spread or an affordable stop. Do not delete it because it would have won afterward. Add the original rule version as a field, because mixing two evolving sets of rules makes the totals hard to interpret. If a data gap hides the next executable quote, record NO VALID FILL rather than inventing the price. If your platform uses different contract multipliers over the sample, document each period separately. Your goal is a reproducible record that another student can challenge, not an impressive screenshot.

5. Calculate results in cash and in risk units

An R-multiple expresses a trade's net result divided by its original planned cash risk. Suppose three fictional completed trades use $10 planned risk each and net results of −$10.50, +$14.50 and −$10.50. Their net R values are −1.05R, +1.45R and −1.05R. Add them: −0.65R across three trades, or about −0.217R per trade. Even though one profit was larger than one loss, the sequence loses overall. Do not quote gross pips while ignoring charges. Track maximum peak-to-trough account decline, losing streaks and the number of trades your rules actually offered. A small sample cannot establish a dependable advantage. When you make a rule change, label the new version and evaluate it separately, including data not used to design the change.

6. Finish with a falsifiable conclusion

After twenty or more chronological teaching cases, produce three paragraphs: What exactly did the rule permit? What did the complete ledger show under stated costs? What information is missing? A falsifiable claim is one that evidence could prove wrong. 'My method works when the market is good' is not precise enough to test. 'Across these fixed dates and assumptions, the net result was below zero' can be checked. Your conclusion should also say which situations the sample did not include and which fills were ambiguous. Do not tune the stop after a loss and quietly recompute the same historical records. A fair next step is to preserve the first sample as development work and move to a genuinely unseen period or a forward paper test. The worksheet is educational research, not a live trading recommendation.

Common mistake

A learner marks a pivot at its turning candle and treats it as known immediately. The confirmation required later bars, which makes the early entry impossible. Fix the test by recording the first timestamp the rule could have fired.

Plain-English glossary

  • Backtest: applying fixed rules to earlier observations.
  • Look-ahead bias: using information that was unavailable at decision time.
  • R-multiple: net trade result divided by initial planned cash risk.
  • Ambiguous fill: an outcome not reliably inferable from the available price sequence.
  • Falsifiable: capable of being disproved by specific evidence.

Try it yourself

Backtest 20 consecutive eligible EURUSD cases in replay. Freeze the strategy version first. For every case log the first knowable signal time, quote assumptions, planned loss, net R, exit path and any skipped or ambiguous outcome. Preserve the entire offered set.

PRACTISE · TEST YOUR UNDERSTANDING

Quick check

Select an answer or type your own for each question. Press Submit practice to review the five responses. This is a formative beta exercise, not a graded assessment.

0 / 5 answered

Question 1

Which timestamp is valid for a pivot requiring two later closed bars?

Question 2

A candle contains both stop and target prices but no tick path. What is the cautious record?

Question 3

What belongs in a fair backtest ledger?

Question 4

True or false: Strong past backtest results guarantee future profit.

Question 5

Calculate: Initial planned risk is $10, actual net loss $10.50. What is the net R-multiple? Show division.

Answer all 5 questions to submit.

What you can now do

  • State a repeatable rule and its main limitation.
  • Recompute the key loss or test statistic using correct units.
  • Keep an auditable record of accepted and rejected decisions.

Next lesson

C07.2 · Forward Paper Testing. Take the same frozen rule into decisions made without historical replay.

Student clarity check

Could you explain the idea in your own words, reproduce the calculation and complete the exercise without seeing an instructor's answer? Does the diagram actually show the concept? Please record exact lesson codes and specific points of confusion for the independent Claude audit.