Look-ahead bias in M1 tests
Posted: Sat Oct 31, 2026 4:08 am
Look-ahead bias happens when a test uses information that wasn't available at the time of the decision. In daily-bar systems it's easy to avoid. In very short-term tests, it sneaks in more subtly.
A common case: a signal computed from the close of a one-minute bar is used to enter at the open of the same bar. The close wasn't known yet. The test appears to buy at the exact start of a move.
Another: an indicator that uses the high or low of the current bar to define a level, and the test enters at that level during the same bar. If the high is only known at the end of the bar, the entry came from the future.
Resampling data also causes it. Building higher timeframe bars from lower ones and aligning them wrongly means a 15-minute bar's close is visible at the start of the 15 minutes.
Results from look-ahead are often too good to be true: smooth equity curves, win rates above 80 percent, very few losing trades. That's a red flag.
A practical test is to shift all signals by one bar and see how the results change. If the profits vanish, the strategy depended on information that wasn't available.
A quick audit of a test script helps: for every value the signal uses, ask when it became known. The close of the current bar becomes known only after the bar ends. A daily high becomes known only after the day ends. Any signal that reads these values early is peeking.
What is the typical sign that a test has a hidden look-ahead problem?
A common case: a signal computed from the close of a one-minute bar is used to enter at the open of the same bar. The close wasn't known yet. The test appears to buy at the exact start of a move.
Another: an indicator that uses the high or low of the current bar to define a level, and the test enters at that level during the same bar. If the high is only known at the end of the bar, the entry came from the future.
Resampling data also causes it. Building higher timeframe bars from lower ones and aligning them wrongly means a 15-minute bar's close is visible at the start of the 15 minutes.
Results from look-ahead are often too good to be true: smooth equity curves, win rates above 80 percent, very few losing trades. That's a red flag.
A practical test is to shift all signals by one bar and see how the results change. If the profits vanish, the strategy depended on information that wasn't available.
A quick audit of a test script helps: for every value the signal uses, ask when it became known. The close of the current bar becomes known only after the bar ends. A daily high becomes known only after the day ends. Any signal that reads these values early is peeking.
What is the typical sign that a test has a hidden look-ahead problem?