# Nasdaq "Initial Balance" breakout: backtest of the rules as stated

Reproducible test of the strategy described on Raj Shamani's *Figuring Out* FO414, 26:48–29:12
(https://www.youtube.com/watch?v=odBTJ4P8yxA&t=1608s). Everything below is generated from code and cached
raw data in this repo. Nothing here is a trade recommendation.

## 0. Summary

<!-- SUMMARY:START -->
Period: 2015-2026 (2026 = Jan-Sep), 2953 NYSE sessions, real Dukascopy BID and ASK 1-minute data.

**Claim:** 60–70% win rate "over the years", 1:2 risk-reward, 2–3 trades a week; the market continues in the IB direction 80–90% of the time.

**What the data shows (target 2R, after costs):**

- stop @ IB other end, 2R, 1st break only: 2937 trades (4.97/week), win rate **44.3%** (95% CI 42.5–46.1), full 2R target hit 11.0%, avg -0.012R per trade, profit factor 0.975, total -34.0R; $10,000 at 1% risk → $6,050 (max drawdown 77.1%); years at 60%+ win rate: **0 of 12**; years with a profit: 6 of 12 (2015 -50R, 2016 -36R, 2017 -23R, 2018 -14R, 2019 +5R, 2020 -13R, 2021 +19R, 2022 +19R, 2023 +23R, 2024 +32R, 2025 +10R, 2026 -6R).
- stop @ 09:30 open, 2R, 1st break only: 2791 trades (4.73/week), win rate **36.7%** (95% CI 34.9–38.5), full 2R target hit 18.1%, avg -0.116R per trade, profit factor 0.81, total -322.9R; $10,000 at 1% risk → $322 (max drawdown 96.8%); years at 60%+ win rate: **0 of 12**; years with a profit: 1 of 12 (2015 -80R, 2016 -72R, 2017 -64R, 2018 -10R, 2019 -5R, 2020 -11R, 2021 -27R, 2022 -6R, 2023 -20R, 2024 +5R, 2025 -7R, 2026 -26R).
- stop @ IB other end, 2R, + reverse after stop: 4079 trades (6.91/week), win rate **44.7%** (95% CI 43.1–46.2), full 2R target hit 10.3%, avg -0.016R per trade, profit factor 0.964, total -65.3R; $10,000 at 1% risk → $4,207 (max drawdown 83.3%); years at 60%+ win rate: **0 of 12**; years with a profit: 5 of 12 (2015 -56R, 2016 -39R, 2017 -34R, 2018 -9R, 2019 -12R, 2020 -6R, 2021 +40R, 2022 +15R, 2023 +14R, 2024 +21R, 2025 +12R, 2026 -11R).
- stop @ 09:30 open, 2R, + reverse after stop: 3692 trades (6.25/week), win rate **35.3%** (95% CI 33.8–36.9), full 2R target hit 18.6%, avg -0.144R per trade, profit factor 0.772, total -530.9R; $10,000 at 1% risk → $37 (max drawdown 99.6%); years at 60%+ win rate: **0 of 12**; years with a profit: 0 of 12 (2015 -119R, 2016 -104R, 2017 -103R, 2018 -17R, 2019 -32R, 2020 -11R, 2021 -16R, 2022 -26R, 2023 -42R, 2024 -17R, 2025 -9R, 2026 -35R).
- stop @ IB other end, 2R, 1st break only, IB-candle direction only: 2510 trades (4.25/week), win rate **45.6%** (95% CI 43.6–47.5), full 2R target hit 10.2%, avg -0.001R per trade, profit factor 0.999, total -1.5R; $10,000 at 1% risk → $8,631 (max drawdown 60.1%); years at 60%+ win rate: **0 of 12**; years with a profit: 8 of 12 (2015 -36R, 2016 -28R, 2017 -19R, 2018 +7R, 2019 +1R, 2020 +8R, 2021 +21R, 2022 +14R, 2023 +5R, 2024 +21R, 2025 +14R, 2026 -9R).
- stop @ 09:30 open, 2R, 1st break only, IB-candle direction only: 2508 trades (4.25/week), win rate **41.2%** (95% CI 39.3–43.2), full 2R target hit 17.2%, avg -0.024R per trade, profit factor 0.955, total -59.4R; $10,000 at 1% risk → $4,648 (max drawdown 70.3%); years at 60%+ win rate: **0 of 12**; years with a profit: 6 of 12 (2015 -42R, 2016 -34R, 2017 -37R, 2018 +24R, 2019 +11R, 2020 +7R, 2021 +12R, 2022 -6R, 2023 -3R, 2024 +12R, 2025 +10R, 2026 -14R).

Across all 18 variants (1R/2R/3R targets, both stops, with/without reversal or IB-direction filter): highest overall win rate 50.6% (stop @ IB other end, 1R, 1st break only, IB-candle direction only); 0 of 216 variant-years reached 60%; 1 variants had a positive average R after costs (stop @ IB other end, 3R, 1st break only, IB-candle direction only: +0.001R).

Costs: with zero spread, slippage and commission the strict variant (stop @ IB other end, 2R, 1st break only) has a 46.2% win rate, +0.050R per trade, profit factor 1.113 (after costs: 44.3%, -0.012R, 0.975). So whether it makes or loses a little money depends on costs, but the win rate is far below 60% either way. Costs weigh most in 2015-2017, when the index was near 4,000-6,000 and a ~1-point CFD spread was a bigger share of the stop distance.

Premise: after a directional first 30 minutes, the rest of the day (10:00 → close) moved the same way on 52.3% of sessions (claim: 80–90%); counting the first 30 minutes' own move, the day closed on the IB candle's side of the open on 66.9%. The 'point of no return' (the far end of the IB never revisited after 10:00) held on 46.3% of sessions (claim: 70–80%); measured on the strict variant's trades, the stop at the far end of the IB survived to the close on 60.6% of trades. Of those trades 49.6% ended at the close with neither stop nor target hit, which is why the average winning trade is only 1.016R, not 2R. The IB was broken on at least one side on 99.5% of sessions, i.e. about 5 signals a week, not 2–3.

Break-even win rate for a clean 1:2 bet is 33.3%. Win = trade closed with net R > 0; most of those are end-of-day exits smaller than 2R, so the full-target hit rate is shown separately.
<!-- SUMMARY:END -->

## 1. The claim (translated from Hinglish; follow the timestamps on the proof page to hear the original)

- 26:48 "There is Nasdaq … The first 30 minutes candle is called initial balance."
- 27:07 "90% of the time … the direction in which initial balance is made, the market continues in that direction. 80–90% of the time."
- 27:22 "if the high break of 30 minutes candle is there, I will buy. If the low break is there, I will sell."
- 27:58–28:15 "as soon as the price will tap above 102, it will be 102.1, I will buy it. And my … stop loss … that will be 100 rupees. Because it was open 100."
- 28:15–28:36 "under open or under the low of the market, my stop loss will be below the low. And this is called point of no return … 70–80% of the time, point of no return is already made."
- 28:36 "suppose the price opened at 100, touched 99 … closed at 102 … my point of no return is 99 … I will buy at 102.1 and my loss will be at 99 … stop loss of 3 rupees … target of 6 rupees. So 1 is to 2."
- 29:07–29:12 "this has a win rate of 60–70%." Raj: "Over the years?" "Over the years." "… in a week, you will get 2–3 trades."

## 2. Rules as tested

All rules sit in `projects/umar-audit/ib_rules.json` and can be changed there. They were written down before the
first full-history run; no parameter was tuned on the results.

| Item | Rule |
|---|---|
| Market | NASDAQ-100, traded as Dukascopy's US Tech 100 CFD (`USATECHIDXUSD`) |
| Initial balance | High and low of the 1-minute BID bars 09:30–09:59 New York time (DST-aware) = the first 30-minute candle |
| Long | Price trades above the IB high after 10:00 |
| Short | Price trades below the IB low after 10:00 |
| Stop, variant A | The other end of the IB (IB low for longs, IB high for shorts), his "point of no return" (99 in his 2nd example) |
| Stop, variant B | The 09:30 open (100 in his 1st example) |
| Target | 2 × risk (1:2), measured from the actual fill. 1R and 3R are run for context |
| Trades per day | One (the first side to break). Variant: if that trade is stopped out, also take a later break of the other side (max 2) |
| Optional filter | "Trade only in its favor": long only if the 30-minute IB candle closed above the 09:30 open, short only if below |
| Exit if neither hit | Flat at the NYSE close (16:00, or 13:00 on half-days) |

18 variants in total: 2 stops × 3 targets × (first break, reverse after stop, IB-direction filter).

### Execution model

- **Entry = resting stop order at the IB level, filled in the breaking minute** (more realistic than next-bar open for a
  breakout trader; the next bar is often far through the level). Long: fires when the BID trades above the IB high,
  fills at the ASK = level + that minute's spread (larger of the open/close spread), or the minute's open if it gapped
  through, plus slippage. Short: fires when the BID trades below the IB low, fills at the BID, minus slippage.
- **Exits use the executable side.** Long stop (sell stop) and target (sell limit) trigger on the BID; short stop
  (buy stop) and target (buy limit) trigger on the ASK. Stops fill at the level or a worse minute open; targets fill
  exactly at the level (no price improvement).
- **Intrabar order is unknown in 1-minute data, so the conservative rule applies:** if stop and target are both inside
  one minute, the stop is assumed first. On the entry minute itself, any touch of the stop counts as a loss, and a
  target counts only if that minute closed beyond it. A day where both IB sides break in the same minute is skipped
  (path unknowable). An upper-bound run with the most generous ordering is reported too.
- **Costs:** the real Dukascopy BID/ASK spread (one spread per round trip), plus 0.5 index points slippage on every
  stop-order and end-of-day market fill, plus 0.25 points commission per round trip (≈ $5 per NQ contract). A zero-cost
  run is reported too.
- **R** = (exit − entry) × direction − commission, divided by the planned risk |entry − stop|. A clean 2R target win is
  +2.00R; a clean stop is about −1.0R (a little worse after slippage).
- **Win** = a trade that closed with net R > 0 (includes small end-of-day profits). The stricter "2R target hit" rate is
  reported next to it. The break-even win rate for a pure 1:2 bet is 33.3%; the table also gives the real break-even
  from the measured average win and loss.
- **Stop = 09:30 open guard:** if the open sits almost on the breakout level the stop distance can shrink to a few
  points, which nobody would trade. Trades with a stop distance under 10% of the IB range are skipped and counted.
- **Money:** $10,000 start, risking 1% of current equity per trade (compounded). Max drawdown is peak-to-trough.

## 3. Results

<!-- RESULTS:START -->
_Generated by `tools/ib_backtest.py run` from 2015-01-02 to 2026-09-30, 2953 NYSE sessions. Win = trade closed with net R > 0 after costs._

### Headline variants (target 2R)

| Variant | Trades | Trades/wk | Win rate (95% CI) | 2R target hit | Avg R | Profit factor | Total R | Max DD (R) | $10k @1% risk → | Max DD @1% | Years ≥60% win |
|---|---|---|---|---|---|---|---|---|---|---|---|
| stop @ IB other end, 2R, 1st break only | 2937 | 4.97 | 44.3% (42.5–46.1) | 11.0% | -0.012 | 0.975 | -34.0 | 140.4 | $6,050 | 77.1% | 0 of 12 |
| stop @ 09:30 open, 2R, 1st break only | 2791 | 4.73 | 36.7% (34.9–38.5) | 18.1% | -0.116 | 0.81 | -322.9 | 323.8 | $322 | 96.8% | 0 of 12 |
| stop @ IB other end, 2R, + reverse after stop | 4079 | 6.91 | 44.7% (43.1–46.2) | 10.3% | -0.016 | 0.964 | -65.3 | 169.9 | $4,207 | 83.3% | 0 of 12 |
| stop @ 09:30 open, 2R, + reverse after stop | 3692 | 6.25 | 35.3% (33.8–36.9) | 18.6% | -0.144 | 0.772 | -530.9 | 530.9 | $37 | 99.6% | 0 of 12 |
| stop @ IB other end, 2R, 1st break only, IB-candle direction only | 2510 | 4.25 | 45.6% (43.6–47.5) | 10.2% | -0.001 | 0.999 | -1.5 | 89.3 | $8,631 | 60.1% | 0 of 12 |
| stop @ 09:30 open, 2R, 1st break only, IB-candle direction only | 2508 | 4.25 | 41.2% (39.3–43.2) | 17.2% | -0.024 | 0.955 | -59.4 | 117.6 | $4,648 | 70.3% | 0 of 12 |

Across all 18 variants: highest overall win rate 50.6% (stop @ IB other end, 1R, 1st break only, IB-candle direction only); best average R +0.001 (stop @ IB other end, 3R, 1st break only, IB-candle direction only); variant-years with a win rate of 60% or more: 0 of 216; variants with positive average R after costs: 1.

### Full grid (all targets)

| Variant | Trades | Win rate | Target hit | Stop | EOD exit | Avg win R | Avg loss R | Break-even win rate | Avg R | PF | Total R | Max DD (R) | Max DD @1% |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| stop @ IB other end, 1R, 1st break only | 2937 | 49.5% | 34.9% | 36.2% | 29.0% | 0.808 | 0.835 | 50.8% | -0.022 | 0.947 | -65.7 | 148.2 | 78.5% |
| stop @ IB other end, 1R, 1st break only, IB-candle direction only | 2510 | 50.6% | 34.6% | 34.1% | 31.3% | 0.791 | 0.816 | 50.8% | -0.003 | 0.991 | -8.7 | 87.7 | 59.6% |
| stop @ IB other end, 1R, + reverse after stop | 3986 | 49.6% | 33.1% | 34.3% | 32.5% | 0.779 | 0.811 | 51.0% | -0.022 | 0.946 | -87.4 | 174.6 | 83.8% |
| stop @ IB other end, 2R, 1st break only | 2937 | 44.3% | 11.0% | 39.4% | 49.6% | 1.016 | 0.829 | 44.9% | -0.012 | 0.975 | -34.0 | 140.4 | 77.1% |
| stop @ IB other end, 2R, 1st break only, IB-candle direction only | 2510 | 45.6% | 10.2% | 37.2% | 52.6% | 0.968 | 0.812 | 45.6% | -0.001 | 0.999 | -1.5 | 89.3 | 60.1% |
| stop @ IB other end, 2R, + reverse after stop | 4079 | 44.7% | 10.3% | 37.2% | 52.5% | 0.96 | 0.804 | 45.6% | -0.016 | 0.964 | -65.3 | 169.9 | 83.3% |
| stop @ IB other end, 3R, 1st break only | 2937 | 43.6% | 3.7% | 39.9% | 56.4% | 1.052 | 0.828 | 44.1% | -0.009 | 0.981 | -26.1 | 140.4 | 77.2% |
| stop @ IB other end, 3R, 1st break only, IB-candle direction only | 2510 | 44.9% | 3.1% | 37.6% | 59.3% | 0.998 | 0.811 | 44.8% | +0.001 | 1.003 | +3.4 | 82.4 | 58.8% |
| stop @ IB other end, 3R, + reverse after stop | 4093 | 43.9% | 3.5% | 37.7% | 58.7% | 0.992 | 0.804 | 44.8% | -0.016 | 0.964 | -66.7 | 178.8 | 84.9% |
| stop @ 09:30 open, 1R, 1st break only | 2791 | 45.8% | 39.1% | 47.5% | 13.3% | 0.895 | 0.969 | 52.0% | -0.116 | 0.78 | -323.4 | 324.3 | 96.6% |
| stop @ 09:30 open, 1R, 1st break only, IB-candle direction only | 2508 | 49.6% | 40.4% | 41.0% | 18.6% | 0.869 | 0.908 | 51.1% | -0.026 | 0.943 | -65.4 | 106.6 | 66.7% |
| stop @ 09:30 open, 1R, + reverse after stop | 3565 | 44.7% | 38.5% | 49.0% | 12.5% | 0.898 | 0.98 | 52.2% | -0.142 | 0.739 | -504.7 | 505.4 | 99.5% |
| stop @ 09:30 open, 2R, 1st break only | 2791 | 36.7% | 18.1% | 55.2% | 26.6% | 1.349 | 0.964 | 41.7% | -0.116 | 0.81 | -322.9 | 323.8 | 96.8% |
| stop @ 09:30 open, 2R, 1st break only, IB-candle direction only | 2508 | 41.2% | 17.2% | 47.6% | 35.2% | 1.233 | 0.905 | 42.3% | -0.024 | 0.955 | -59.4 | 117.6 | 70.3% |
| stop @ 09:30 open, 2R, + reverse after stop | 3692 | 35.3% | 18.6% | 57.0% | 24.4% | 1.377 | 0.975 | 41.5% | -0.144 | 0.772 | -530.9 | 530.9 | 99.6% |
| stop @ 09:30 open, 3R, 1st break only | 2791 | 34.5% | 9.2% | 57.1% | 33.6% | 1.516 | 0.964 | 38.9% | -0.108 | 0.829 | -301.1 | 301.1 | 96.2% |
| stop @ 09:30 open, 3R, 1st break only, IB-candle direction only | 2508 | 39.5% | 7.7% | 49.0% | 43.2% | 1.34 | 0.905 | 40.3% | -0.019 | 0.965 | -48.0 | 118.5 | 70.8% |
| stop @ 09:30 open, 3R, + reverse after stop | 3722 | 33.0% | 9.9% | 58.9% | 31.1% | 1.573 | 0.974 | 38.2% | -0.133 | 0.797 | -494.0 | 494.9 | 99.5% |

### Yearly win rate, headline variants (2R)

| Year | stop @ IB other end, 1st break only | stop @ 09:30 open, 1st break only | stop @ IB other end, + reverse after stop | stop @ 09:30 open, + reverse after stop | stop @ IB other end, 1st break only, IB-candle direction only | stop @ 09:30 open, 1st break only, IB-candle direction only |
|---|---|---|---|---|---|---|
| 2015 | 36.5% (252, -50R) | 29.6% (243, -80R) | 39.4% (373, -56R) | 29.1% (347, -119R) | 39.6% (222, -36R) | 36.5% (222, -42R) |
| 2016 | 38.6% (249, -36R) | 31.4% (236, -72R) | 39.0% (346, -39R) | 29.6% (318, -104R) | 39.7% (209, -28R) | 36.8% (209, -34R) |
| 2017 | 40.6% (251, -23R) | 31.7% (243, -64R) | 41.5% (340, -34R) | 30.2% (318, -103R) | 42.1% (209, -19R) | 35.4% (209, -37R) |
| 2018 | 39.0% (249, -14R) | 36.5% (233, -10R) | 41.4% (360, -9R) | 37.3% (316, -17R) | 43.5% (223, +7R) | 43.9% (221, +24R) |
| 2019 | 45.0% (249, +5R) | 39.3% (234, -5R) | 43.7% (332, -12R) | 36.0% (297, -32R) | 44.4% (207, +1R) | 42.5% (207, +11R) |
| 2020 | 44.3% (253, -13R) | 38.4% (242, -11R) | 47.9% (365, -6R) | 39.0% (326, -11R) | 49.1% (220, +8R) | 44.5% (220, +7R) |
| 2021 | 50.0% (250, +19R) | 39.7% (239, -27R) | 51.5% (334, +40R) | 40.6% (315, -16R) | 53.2% (205, +21R) | 47.8% (205, +12R) |
| 2022 | 47.6% (250, +19R) | 39.8% (236, -6R) | 46.7% (349, +15R) | 36.9% (312, -26R) | 46.3% (214, +14R) | 40.2% (214, -6R) |
| 2023 | 47.6% (248, +23R) | 37.3% (228, -20R) | 46.8% (344, +14R) | 35.0% (300, -42R) | 45.1% (206, +5R) | 41.3% (206, -3R) |
| 2024 | 47.2% (252, +32R) | 39.7% (242, +5R) | 44.8% (348, +21R) | 36.5% (315, -17R) | 46.7% (214, +21R) | 41.6% (214, +12R) |
| 2025 | 48.0% (250, +10R) | 39.7% (239, -7R) | 47.4% (342, +12R) | 38.8% (304, -9R) | 49.8% (223, +14R) | 43.5% (223, +10R) |
| 2026 (to 09-30) | 48.4% (184, -6R) | 37.5% (176, -26R) | 47.2% (246, -11R) | 36.2% (224, -35R) | 48.1% (158, -9R) | 40.5% (158, -14R) |

Cell = win rate (trades, total R).

### Same headline variants with zero costs (no spread, slippage or commission)

| Variant | Trades | Win rate | Target hit | Avg R | PF | Total R | Years ≥60% |
|---|---|---|---|---|---|---|---|
| stop @ IB other end, 2R, 1st break only | 2937 | 46.2% | 12.6% | +0.050 | 1.113 | +146.7 | 0 |
| stop @ 09:30 open, 2R, 1st break only | 2736 | 39.8% | 21.2% | +0.008 | 1.015 | +22.1 | 0 |
| stop @ IB other end, 2R, + reverse after stop | 4072 | 46.9% | 11.8% | +0.047 | 1.112 | +192.5 | 0 |
| stop @ 09:30 open, 2R, + reverse after stop | 3547 | 39.1% | 22.2% | +0.003 | 1.006 | +11.8 | 0 |
| stop @ IB other end, 2R, 1st break only, IB-candle direction only | 2510 | 47.6% | 11.8% | +0.062 | 1.147 | +155.2 | 0 |
| stop @ 09:30 open, 2R, 1st break only, IB-candle direction only | 2507 | 43.5% | 19.6% | +0.064 | 1.129 | +161.1 | 0 |

Per year, stop @ IB other end, 2R, 1st break only, after costs vs zero costs:

| Year | Trades | Win rate (costs) | Total R (costs) | Win rate (no costs) | Total R (no costs) |
|---|---|---|---|---|---|
| 2015 | 252 | 36.5% | -50.2 | 41.7% | -12.6 |
| 2016 | 249 | 38.6% | -36.4 | 41.4% | -11.5 |
| 2017 | 251 | 40.6% | -23.4 | 43.0% | +8.1 |
| 2018 | 249 | 39.0% | -14.3 | 41.8% | +7.3 |
| 2019 | 249 | 45.0% | +5.1 | 48.6% | +24.7 |
| 2020 | 253 | 44.3% | -12.6 | 44.7% | -3.4 |
| 2021 | 250 | 50.0% | +19.1 | 51.6% | +28.5 |
| 2022 | 250 | 47.6% | +18.9 | 49.6% | +22.8 |
| 2023 | 248 | 47.6% | +23.4 | 47.6% | +28.9 |
| 2024 | 252 | 47.2% | +32.1 | 48.0% | +43.0 |
| 2025 | 250 | 48.0% | +10.3 | 48.4% | +14.8 |
| 2026 | 184 | 48.4% | -6.0 | 48.4% | -3.9 |

### Same headline variants with the most generous intrabar assumption (full costs)

Stop on the entry minute only if that minute closed beyond the stop; a stop/target tie in one minute goes to the target. This is an upper bound, not the headline.

| Variant | Trades | Win rate | Target hit | Avg R | PF | Total R | Years ≥60% |
|---|---|---|---|---|---|---|---|
| stop @ IB other end, 2R, 1st break only | 2937 | 44.3% | 11.0% | -0.012 | 0.975 | -34.0 | 0 |
| stop @ 09:30 open, 2R, 1st break only | 2791 | 38.7% | 20.1% | -0.054 | 0.908 | -150.5 | 0 |
| stop @ IB other end, 2R, + reverse after stop | 4079 | 44.7% | 10.4% | -0.014 | 0.969 | -56.2 | 0 |
| stop @ 09:30 open, 2R, + reverse after stop | 3676 | 37.8% | 21.1% | -0.067 | 0.888 | -247.8 | 0 |
| stop @ IB other end, 2R, 1st break only, IB-candle direction only | 2510 | 45.6% | 10.3% | +0.001 | 1.001 | +1.5 | 0 |
| stop @ 09:30 open, 2R, 1st break only, IB-candle direction only | 2508 | 41.5% | 17.4% | -0.016 | 0.969 | -41.1 | 0 |

### Second data source: HistData.com NSXUSD 1-minute (BID only, so no costs), same sessions

| Variant | Trades | Win rate | Target hit | Avg R | PF | Total R | Years ≥60% |
|---|---|---|---|---|---|---|---|
| stop @ IB other end, 2R, 1st break only | 2868 | 46.0% | 12.9% | +0.049 | 1.111 | +140.4 | 0 |
| stop @ 09:30 open, 2R, 1st break only | 2669 | 40.2% | 21.9% | +0.023 | 1.041 | +60.8 | 0 |
| stop @ IB other end, 2R, + reverse after stop | 3977 | 46.7% | 12.3% | +0.052 | 1.122 | +204.9 | 0 |
| stop @ 09:30 open, 2R, + reverse after stop | 3447 | 39.8% | 23.0% | +0.024 | 1.044 | +84.3 | 0 |
| stop @ IB other end, 2R, 1st break only, IB-candle direction only | 2436 | 47.3% | 12.2% | +0.064 | 1.152 | +156.4 | 0 |
| stop @ 09:30 open, 2R, 1st break only, IB-candle direction only | 2433 | 43.1% | 19.8% | +0.060 | 1.119 | +145.4 | 0 |

Day-level agreement with Dukascopy (strict variant, no costs): 2947 sessions, same first-breakout side 95.1%, same side and same exit type 93.6%, median |IB high diff| 0.0 pts, |IB low diff| 0.0 pts.
HistData premise check: rest-of-day continues IB direction 52.5%, point of no return held 45.8%.

### The premise behind the rule

- Sessions with a directional IB candle: 2952
- Rest of the day (10:00 → close) moved in the IB candle's direction: **52.3%** (claim: 80–90%)
- Day closed on the IB candle's side of the 09:30 open: 66.9%
- 'Point of no return' held (bullish IB: IB low never broken after 10:00; bearish: IB high never broken): 46.3% (claim: 70–80%)
- IB broken on at least one side after 10:00: 99.5% of sessions; on both sides: 39.3%

### Data

- Dukascopy Bank historical datafeed (datafeed.dukascopy.com), USATECHIDXUSD (US Tech 100 / NASDAQ-100 CFD), 1-minute BID and ASK. Period 2015-2026 (2026 = Jan-Sep) (2015-01-02 → 2026-09-30), 2953 sessions; by year: 2015: 252, 2016: 252, 2017: 251, 2018: 251, 2019: 252, 2020: 253, 2021: 252, 2022: 251, 2023: 250, 2024: 252, 2025: 250, 2026: 187.
- Real ASK file on 2953 sessions; modelled ASK on 0.
- 7 sessions where the CFD feed went flat for part of the session (no ticks; the stale last price is used): 2015-11-02 (390 rows, 331 active of 390 expected minutes), 2015-11-03 (390 rows, 331 active of 390 expected minutes), 2015-11-04 (390 rows, 331 active of 390 expected minutes), 2015-11-05 (390 rows, 331 active of 390 expected minutes), 2015-12-31 (390 rows, 211 active of 390 expected minutes), 2017-07-03 (210 rows, 136 active of 210 expected minutes), 2023-11-24 (210 rows, 164 active of 210 expected minutes).
- Median session spread (points) by year: 2015: 1.06, 2016: 1.02, 2017: 1.06, 2018: 1.07, 2019: 1.07, 2020: 1.44, 2021: 1.45, 2022: 1.44, 2023: 1.45, 2024: 1.46, 2025: 1.4, 2026: 1.12
- Median price by year: 2015: 4,443, 2016: 4,543, 2017: 5,793, 2018: 6,955, 2019: 7,672, 2020: 10,350, 2021: 14,554, 2022: 12,408, 2023: 14,693, 2024: 19,006, 2025: 22,671, 2026: 28,549
<!-- RESULTS:END -->

## 4. Sanity checks

- **Spot checks.** `tools/ib_backtest.py spot` prints sessions bar by bar (IB bars, the bars around entry and exit,
  BID and ASK) with the trade decision for both stop variants. Five random sessions (2015-05-26, 2016-03-24,
  2017-08-21, 2023-03-21, 2025-04-24; `data_raw/spotcheck.txt`) were checked by hand: IB high/low match the bars, the
  entry is the first minute that trades through the level, the long fill = level + spread + 0.5 slippage, the short
  fill = level − 0.5, and every R recomputes from the printed prices (e.g. 2025-04-24 long: (19204.14 − 18948.86 −
  0.25) / 214.02 = +1.19R). All five entered in the 10:00 minute (30% of all strict-variant trades enter at 10:00 and 83% before 10:30): price is often sitting at an IB extreme
  when the IB closes. The full run adds five more random sessions in `data_raw/spotcheck_full_random.txt`.
- **DST.** Bars are stored in UTC by Dukascopy and converted to America/New_York, so the 09:30 bar is 14:30 UTC in
  winter and 13:30 UTC in summer, including the weeks when Europe and the US are on different clocks. The spot
  output lists the sessions either side of every US clock change: all start at 09:30 local (offset −05:00 / −04:00).
- **Holidays and half-days.** Sessions come from the NYSE calendar (`exchange_calendars`, XNYS), so market holidays and
  special closures (e.g. 5 Dec 2018, 9 Jan 2025) are excluded and half-days end at 13:00 (exit at the 12:59 bar).
  The spot output lists every half-day with its last bar.
- **Feed gaps.** Every session is checked for missing or tick-less minutes (`data_raw/usatech_gaps.json`); the few
  sessions where the CFD went flat for part of the session are listed under Data above.
- **Second source, full history.** HistData.com's free NSXUSD (NASDAQ 100) 1-minute file was run through the same
  engine (BID only, so no costs) and compared day by day with Dukascopy (table above). Finding while doing this:
  HistData says its stamps are "EST without DST", but for this symbol they only line up with Dukascopy when read as
  New York local time (1-minute return correlation 0.97–1.00 at lag 0 in both winter and summer, about 0 at
  ±60 min). In recent years HistData's NSXUSD is identical to Dukascopy's BID feed, so for those years it checks our
  parsing and time handling rather than the market; in 2015 it is a different feed (levels 3–8 points apart).
- **Independent instruments, recent days.** Yahoo only serves ~30 days of 1-minute data, so NQ=F (the actual Nasdaq
  futures) and QQQ were compared with Dukascopy on the 17 overlapping sessions of September 2026 (strict rule, no
  costs; `data_raw/crosscheck_yahoo_vs_dukascopy.csv`). Same IB direction and same first-breakout side on 17/17 days
  for both; same exit type on 14/17 (NQ=F) and 16/17 (QQQ). The differences: on 14 Sep Yahoo's continuous NQ=F series
  rolls from the September to the December contract mid-session (a ~300-point jump), which fakes a target hit; on
  15 Sep the short target was reached by 3 points on NQ=F and missed by 19 points on the CFD; on 30 Sep the long's
  stop was hit by 2 points on NQ=F/QQQ and missed by 1 point on the CFD. Near misses, not systematic differences.

## 5. Limitations and interpretation choices

- **CFD, not the futures contract.** Most retail traders following this trade a NAS100/US100 CFD, which is what
  was tested. NQ futures trade on a slightly different price (basis) and have their own costs; the September 2026
  comparison above shows the same signals and nearly the same outcomes on NQ=F and QQQ, but fills on real futures
  would differ by small amounts.
- **Rule interpretation.** We tested the rules as spoken. His two examples use two different stops (the open, then
  the IB low), so both are tested. He did not say what happens if neither stop nor target is hit (we exit at the
  close), whether a second trade is allowed after a stop (both tested), or whether he filters days. His "2–3 trades a
  week" against ~5 signals a week from the stated rule suggests he skips days for reasons he did not describe; any
  such filter would be a different strategy and would need its own test.
- **"Win rate" definition.** We count any trade closing in profit as a win, which is generous to the claim; the
  stricter full-target hit rate is much lower.
- **1-minute data.** The order of high and low inside a minute is unknown. The headline uses the conservative rule
  (stop first); the "most generous" table shows how much that matters.
- **Costs.** Spread is Dukascopy's; slippage (0.5 pt) and commission (0.25 pt) are assumptions stated in
  `ib_rules.json`. The zero-cost table shows the conclusion does not depend on them.
- **Statistics.** Win-rate intervals are 95% Wilson intervals; yearly samples are ~250 trades, so a year's win rate
  carries roughly ±6 points of noise. 18 variants were tested and all are reported; nothing was optimised.
- **Interim runs.** If the summary says INTERIM, the period is partial and part of the ASK side is modelled from
  nearby days' real spreads. The full run uses the same rules and code.

## 6. Reproduce

```bash
.venv/bin/python tools/ib_data.py fetch        # Dukascopy BID+ASK 1-min, resumable (skips cached files)
.venv/bin/python tools/ib_data.py histdata     # second source, HistData NSXUSD 1-min
.venv/bin/python tools/ib_data.py build        # NY sessions -> data_raw/usatech_session_1m.pkl + usatech_gaps.json
.venv/bin/python tools/ib_backtest.py run      # all variants -> engine/public/projects/umar-audit/data/ib_results.json + tables above
.venv/bin/python tools/ib_backtest.py spot --n 5      # random days, bar by bar, plus DST / half-day check
.venv/bin/python tools/ib_backtest.py crosscheck      # Yahoo NQ=F and QQQ 1-min vs Dukascopy (last ~30 days only)
.venv/bin/python tools/ib_backtest.py plots           # data_raw/check_equity_curves.png, check_yearly_winrate.png
```

Files: raw `.bi5` files under `projects/umar-audit/data_raw/dukascopy/USATECHIDXUSD/` (month folder is 0-based, as in
the feed), HistData zips under `data_raw/histdata/`, Yahoo CSVs under `data_raw/yahoo/`, trade lists
`data_raw/ib_trades_*.csv`, spot-check log `data_raw/spotcheck.txt`.
