Quant from Scratch by QuantWright

Testing Popular Ideas · Lesson 11

SMC: market structure

Swing highs and lows, breaks of structure and changes of character: how often they appear when there is nothing to find, and the 24 versions of a rule built on them.

Know the basics? Read the lesson notes

Swing highs and swing lows

Smart money concepts (SMC) are a set of chart-reading terms popular online. Several lessons cover ideas that traders group under 'smart money concepts' (SMC): fair value gaps, order blocks, liquidity sweeps, market structure. They spread through free video lectures and are now taught by many educators, each with their own definitions. We code one common reading, show the switches where readings differ, and test that. It is our reading, not anyone's official method. Market structure comes first; the others each get their own lesson.

Market structure starts from turning points. Each mark below is one day: a thin line from its lowest price to its highest, and a box from its first price (the open) to its last (the close). A swing high is a day whose high is above the highs of the n days before it and the n days after it; a swing low is a day whose low is below theirs. The number n is the swing's width, and it is a choice. A swing high is known only n days later, once the days after it are in.

The prices are simulated: made up by a computer, not a real market. These markets were built so that past prices say nothing about which way the next move goes; the counts in this lesson show what structure rules do when there is nothing to find. They cannot show whether the idea works in a real market. Try all three widths.

100 days, daily candles (simulated)

Filled dot: a swing high. Ring: a swing low. Short dashed line: the days until the swing is known.

Width
Swing highs–
Swing lows–

Width 2 marks 13 swing highs and 15 swing lows in these 100 days; width 10 marks 1 and 3. The same prices give a different picture of where the turns were.

Higher highs, higher lows

Traders read the swings in order. A swing high above the swing high before it is a higher high; a swing low above the one before it, a higher low. Higher highs and higher lows are read as a rise; lower highs and lower lows as a fall. Reading the swings this way is reading the market's structure.

The same 100 days, width 5 (simulated)

HH: higher high. LH: lower high. HL: higher low. LL: lower low.

In markets built with no pattern, what share of swing highs (width 5) is above the swing high before it?

Far too few. With no pattern, the next swing high is about as likely to be higher as lower.
Far too many. With no pattern, the next swing high is about as likely to be higher as lower.
About half: across 1,000 simulated markets, 54.5 in 100. A little over half, because these markets rise slowly on average. In the 100 days above, 3 of 6.

So runs of higher highs and higher lows turn up with nothing to find. Reading them as a rise describes the past; it does not say where the next move goes in these markets.

Break of structure, change of character

A rule needs a moment to act. Keep a trend: up, down, or none at first. Each day, look at the latest swing high and swing low that are already known. A close above that swing high breaks it upward; a close below that swing low breaks it downward. Each swing can break only once.

The first break sets the trend. After that, a break in the trend's direction is a break of structure (BOS), and the trend stays. A break against it is a change of character (CHoCH), and the trend flips. Step through the breaks on these 100 days, width 5.

Breaks on the 100 days, width 5 (simulated)

Dashed: the level that broke, from its swing to the break. Shading: the trend after each break (orange up, grey down).

Break–
Trend after–

Six breaks in 100 days: the first on 9 Feb (down), a change of character up on 16 Feb, two breaks of structure up, a change of character down on 28 Mar and a break of structure down on 27 Apr.

Close or wick

Two more choices. The swings can be read from each day's high and low, the wicks (the thin lines), or from the closes. A break can need a close past the level, or only a wick past it. Try both of each, at width 5.

Two readings of one break (simulated)

The breaks of the reading chosen with the two switches; switch them to compare. Shading: the trend.

Swings
Break
Changes of character–
Breaks of structure–

With wick swings and close breaks, the trend changed character twice, on 16 Feb and 28 Mar. With close swings and close breaks, the first break came only on 27 Feb, and the one change of character on 24 Mar.

Which low must break?

In a rising trend, which low must break for a change of character? One reading takes the latest swing low. Another takes the low that the last rise started from: the lowest price between the swing high just broken and the break. That low usually sits further down, and the small dips after it don't count. A falling trend works the same way with highs. Try both at width 2, where they often differ.

Two choices of level, width 2 (simulated)

Wick swings, close breaks; switch Level to compare. Shading: the trend.

Level
Changes of character–

With the latest swing, five changes of character in 100 days. With the start of the move, two: the dips in between no longer flip the trend.

How many versions?

Each different set of choices is a version: the same idea with different settings (the How we test an idea lesson). Width (2, 5 or 10 days), swings from wicks or closes, a break by close or wick, the latest swing or the start of the move: how many versions?

That adds the choices (3 + 2 + 2 + 2). Every choice goes with every other, so they multiply.
That leaves out one of the four switches. Three widths, then two choices for each of the other three.
3 widths × 2 swing readings × 2 breaks × 2 levels = 24 versions.

How often, with nothing to find?

Take one exact reading: width 5, swings from the wicks, a break by a close, the latest swing. Call it the baseline version: this lesson's starting point, not anyone's published rule.

Guess: in a market built with no pattern, how many changes of character a year does it find?

Breaks a year with nothing to find (simulated)

Averaged over 1,000 simulated markets and ten years. Wick swings, close breaks, latest swing, at each width. Pale: breaks of structure. Dark: changes of character.

The 10-year market?
1,000 markets?

Across 1,000 simulated markets, the baseline version found 6.2 changes of character a year, and as many breaks of structure; on the lesson's 10-year market (not the 100 days above), 6.9 a year.

Did a change of character mark a turn? After one, the next break went the new way, a break of structure, 49.6 times in 100, and flipped back the other 50.4: a coin toss, in these markets.

For the preciseTen years of 2,607 days in each market. Wick swings, close breaks, latest swing: width 2, 13.1 breaks of structure and 12.3 changes of character a year; width 5, 6.2 and 6.2; width 10, 3.3 and 3.4. With the start of the move at width 5, 3.8 changes of character a year, and after one the next break was a break of structure 71.4 times in 100: that level sits further away, so the next break is more often the near swing in the new direction. Swing highs at width 5 (wicks): 15.4 a year.

One version against just holding

A rule built on the baseline version: own the market while the trend is up; hold cash while it is down or not yet set. Decide at each close; buy or sell at the next day's open.

It runs from 2015 to 2021 against just holding: buying once and never selling. Each buy and each sale costs 0.1% of the price (the Costs lesson); holding pays that once. Results are in % a year: the steady yearly growth that gives the same total. Holding made 4.4% a year. Where did the rule end, after costs?

The baseline version and just holding, 2015–2021, after costs (simulated)

Accounts starting at 100. Orange: the baseline version. Dotted: holding.

Your guess: it ends
Baseline version?
Holding?

It lost 3.7% a year after costs, 8.1 points a year behind holding (a point is 1% a year). Costs were not the main reason: it bought 3.6 times a year and sold as often, about 0.7 points a year. One market is one draw, so run it on 1,000 more.

The baseline version against holding on 1,000 simulated markets

Bars: markets, by the version's % a year minus holding's. Grey: after costs. Orange outline: before costs.

After costs it beat holding in 175 of the 1,000 simulated markets. The reason it mostly trailed: across these markets holding made 8.2% a year on average, and the rule held cash on about 44 days in 100, so it missed about 0.44 × 8.2 ≈ 3.6 points a year of the rise. Its average lag was 3.75 points a year before costs and 4.38 after. The 175 are mostly markets where holding did poorly: in 150 of them holding made less than its 8.2% average (holding was under 8.2 in 520 of all 1,000 markets; when holding earns little or falls, sitting in cash costs little or even helps).

For the preciseBefore costs it beat holding in 200 of the 1,000 simulated markets. Holding (2015–2021, after its one cost) rose in 876 of the 1,000; where it fell by more than 5% a year (32 markets), the rule beat it after costs in 25. It was long on 55.9 days in 100 and bought 3.14 times a year, on average. Its opposite, the same structure owning the market only while the trend was down, beat holding before costs in 218 of the 1,000 (average lead −4.79). On the market shown, that opposite beat holding by 3.7 points a year after costs.

Again: these markets have nothing to find, so this shows what the rule does then, not whether it works in a real market.

All 24 versions

Here are all 24 versions on the same simulated market and years, 2015 to 2021. Each bar is a version's % a year minus holding's, in points. Show them, then turn the costs on.

24 versions: each one's lead over holding, 2015–2021 (simulated)

One bar per version, grouped by width. Above the line: beat holding. Black: the baseline version. Solid orange: the best.

Costs
Beat holding?
The best?

On this market 2 of the 24 beat holding before costs, and none after. The best after costs (solid orange) trailed holding by 1.9 points a year. It was the best before costs too, +1.6, and it traded most, 16.9 buys a year, so costs took about 3.5 points a year from it. The baseline version came 18th of 24: its place, counting from the version furthest ahead of holding.

On the 1,000 simulated markets, after costs, 3.9 of the 24 beat holding on average, and at least one did in 492.

Does the best stay best?

Before any version was run, 2022 to 2024 were set aside: years held out, to be used once (the held-out test lesson).

On each of the 1,000 simulated markets we took the best of the 24 on 2015–2021, after costs, and ran it once on 2022–2024. A blind draw, one version taken at random, would be best there in about 42 of 1,000 (1,000 ÷ 24 = 41.7). Guess how often the best stayed best.

The best version's place on 2022–2024, on 1,000 simulated markets, after costs

One bar per place, 1st on the left. Dashed: a blind draw.

Stayed best?

The best stayed best in 47 of the 1,000 simulated markets, against a blind draw's 42: 47 against 42 is within chance, since about ±6 either way is noise, and these markets have nothing to find, so it is not skill.

On 2015–2021 the best looked level with holding: −0.03 points a year on average. On 2022–2024 it trailed by 4.41, about what the baseline version did (−4.07). Its result did not carry over.

For the preciseThe best on 2015–2021 had width 10 in 457 of the 1,000 simulated markets, 2 in 272, 5 in 271; it beat holding there in 492 and on 2022–2024 in 263; its average place on 2022–2024 was 12.2 of 24. One market had a tie for first place on the held-out years. Of all 24,000 held-out results after costs, 25.3 in 100 beat holding.
Theory

How many swings a market with no pattern makes

Swings need no pattern. Suppose every day brings the same kind of move, as likely a rise of any size as a fall of the same size, independently of the other days, and never exactly zero. A close is a swing high (close reading, width n) when the price stays below it for each of the next n days and was below it for each of the n days before. Each side has the same chance, qn, and the two sides don't affect each other, so the chance is qn squared. That qn does not depend on the size of the moves is the Sparre Andersen theorem.

P(swing high) = qn2,   qn = ½ × ¾ × ⅚ × … × (2n − 1) ÷ (2n)
n
the width: the days on each side
qn
the chance the price stays below a given close for each of the next n days, when every day brings the same kind of move, as likely a rise of any size as a fall of the same size, independently, never exactly zero
P(swing high)
the chance a given close is a swing high of width n (close reading), under the same conditions; a swing low has the same chance
Worked example: width 2

q2 = ½ × ¾ = 3/8, not ½ × ½: the price only has to stay below, so down 1% then up 0.5% still counts. P = (3/8)² = 9/64 = 0.141: about 14.1 closes in 100 are swing highs. Across the 1,000 simulated markets, 13.9 in 100 were (width 2, close reading); at width 5, 6.0 against (63/256)² = 6.1.

Holds when
  • the same kind of move every day, a rise of any size as likely as a fall of the same size;
  • days are independent (one day's move tells you nothing about the next);
  • no two closes exactly equal (no move is exactly zero).
Breaks when

A drift (these markets rise slowly), calm and wild spells (the size of moves clusters) or prices rounded to cents (ties: equal ±$1 steps would give ¼, not 3/8, at width 2) make it a little off: the counts here sit just under it. Swings read from wicks need other numbers, since a day's high is not its close. A real market needs its own count.

Width 3, in a market with no pattern: about how many closes in 100 are swing highs?

q3 = ½ × ¾ × ⅚ = 5/16 = 0.3125; squared, 0.0977: 9.8 in 100.
q3 = ½ × ¾ × ⅚ = 5/16 = 0.3125. P = 0.3125² = 0.0977, so about 9.8 closes in 100.

What this means for your test

  1. Write every switch down before you run it.

    The width; wicks or closes for the swings; a close or a wick for the break; which low counts; when the rule buys and sells; the costs.

Practice 1 of 3

A bigger search

The situationA friend tests widths of 2, 3, 5, 8 and 10 days, wick or close swings, a break by close or wick, the latest swing or the start of the move, and buying at the break or one day later. Then they check whether the best stays best on held-out years across 1,000 simulated markets.

In about how many of the 1,000 would a blind draw be best?

Hint: first multiply the choices to get the number of versions, then divide 1,000 by it.

5 × 2 × 2 × 2 × 2 = 80 versions; 1,000 ÷ 80 = 12.5.
Versions: 5 widths × 2 × 2 × 2 × 2 = 80. A blind draw is best in about 1,000 ÷ 80 = 12.5 of 1,000.
Practice 2 of 3

Every top marked

The situationAn invented post shows a chart with every swing high of width 5 marked, and says a rule "sold at every top".

What is the likeliest problem?

A swing high needs the 5 days after it. A rule can act only once they are in, never at the top itself; marks drawn on a finished chart show what nobody could know on the day.
Wicks or closes changes which days are swings, but either way the swing is known only once the 5 days after it are in, never at the top itself.
No width makes the marks usable on the day: a swing high of width 5 is known only once the 5 days after it are in, never at the top itself.
Practice 3 of 3

Counting swings

The situationA friend counts swing highs by close, width 4, over 250 days of a made-up market where each day's move is as likely a rise of any size as a fall of the same size, independently, never exactly zero.

About how many swing highs should they expect?

Hint: q4 = ½ × ¾ × ⅚ × ⅞. Square it, then multiply by 250.

q4 = 35/128 = 0.2734; squared, 0.0748; × 250 = 18.7.
q4 = ½ × ¾ × ⅚ × ⅞ = 35/128 = 0.2734. P = 0.0748, and 250 × 0.0748 = 18.7 swing highs.
✓

Lesson done

Market structure reads swing highs and lows of a chosen width: a break in the trend's direction is a break of structure, a break against it a change of character. The width, wick or close, and which low counts made 24 versions here. These simulated markets were built so that past prices say nothing about which way the next move goes, so the counts show what these rules produce when there is nothing to find: the baseline version found about 6 changes of character a year, after which the next break went either way about equally often; owning the market only in an up trend beat just holding after costs in only 175 of 1,000 simulated markets; it mostly trailed because it held cash about 44 days in 100 while these markets rose on average; the best of 24 stayed best on held-out years in 47 (a blind draw: about 42). In a market whose days are independent, each as likely a rise of any size as a fall of the same size, swings appear at a rate the Sparre Andersen theorem gives. The counts cannot show whether market structure works in any real market.

Key ideas

Swing high, swing low
a day whose high is above (low is below) those of the n days either side; known only n days later
Width
the n days on each side a swing needs; a choice
Break of structure (BOS)
a break of the latest swing level in the trend's direction; the trend stays
Change of character (CHoCH)
a break against the trend; the trend flips. Which low or high counts is a choice
Wick, close
reading swings or breaks from a day's high and low, or from its close
Version
the same idea with different settings; count every one

Formulas

P(swing high) = qn2, qn = ½ × ¾ × … × (2n − 1) ÷ (2n), for closes, width n, when every day brings the same kind of move, as likely a rise of any size as a fall of the same size, independently, never exactly zero (the Sparre Andersen theorem)

Lesson notes

Market structure, one of the ideas traders group under smart money concepts (SMC), reads a chart through its swing highs and lows: a break of the latest swing level in the trend's direction is a break of structure, a break against it a change of character. The swing width, wicks or closes, a close or a wick for the break, and which low counts made 24 versions in this lesson. Its simulated markets were built so that past prices say nothing about which way the next move goes, so its counts show what these rules produce when there is nothing to find. There, the breaks came several times a year, the next break after a change of character went either way about equally often, and a rule that owned the market only in an up trend trailed just holding (buying on the first day and never selling) in most of 1,000 simulated markets after costs (it beat holding in only 175); it mostly trailed because it held cash about 44 days in 100 while these markets rose on average. The counts cannot show whether market structure works in any real market; that needs its own test.

Swings and their width

Each candle in the lesson is one simulated day: its open, high, low and close. A swing high of width n is a day whose high is above the highs of the n days before it and the n days after it; a swing low is a day whose low is below theirs. The width is a choice. On the lesson's 100 example days (simulated), width 2 marked 13 and 15 swing highs and lows, width 10 only 1 and 3. A swing high is known only n days after it, once the days after it are in: a rule can act on it then, never at the top itself.

A swing high above the swing high before it is a higher high; a swing low above the one before it, a higher low. Traders read higher highs and higher lows as a rise. Across 1,000 simulated markets with no pattern, 54.5 swing highs in 100 (width 5, wicks) were higher highs: about half, a little over because these markets rise slowly on average.

Breaks of structure and changes of character

The rule keeps a trend: none at first. Each day it looks at the latest swing high and swing low that are already known. A close above that swing high is a break up, a close below that swing low a break down, and a broken swing is used up. The first break sets the trend; after that, a break in the trend's direction is a break of structure (BOS) and the trend stays; a break against it is a change of character (CHoCH) and the trend flips. On the example days at width 5, the first break came on 9 Feb (down), a change of character up on 16 Feb, two breaks of structure up, a change of character down on 28 Mar and a break of structure down on 27 Apr.

Three switches change these events. The swings can be read from the wicks (each day's high and low) or from the closes, and a break can need a close past the level or only a wick past it: on the example days, wick swings with close breaks gave two changes of character (16 Feb, 28 Mar), close swings with close breaks gave one (24 Mar). The change of character can need the latest swing low (in a rising trend), or the low the last rise started from, the lowest price between the swing high just broken and the break: at width 2 on the example days, five changes of character against two. Three widths and two choices for each of the other three switches make 3 × 2 × 2 × 2 = 24 versions.

How often, with nothing to find

The baseline version, the lesson's starting point, uses width 5, wick swings, close breaks and the latest swing. Across the 1,000 simulated markets it found 6.2 changes of character a year and as many breaks of structure. After a change of character, the next break was a break of structure in the new direction 49.6 times in 100 and a change back the rest: a coin toss, in these markets.

The baseline version against just holding

The rule owns the market while the trend is up and holds cash otherwise, deciding at each close and trading at the next day's open. Each buy and each sale costs 0.1% of the price; holding pays that once. From 2015 to 2021 on the lesson's simulated market, holding made 4.4% a year after its cost (% a year: the steady yearly growth that gives the same total). The rule lost 3.7% a year after costs, 8.1 points a year behind holding (a point is 1% a year). Costs were not the main reason: it bought 3.6 times a year and sold as often, about 0.7 points a year. On the 1,000 simulated markets it beat holding after costs in 175. Across them holding made 8.2% a year on average, and the rule held cash on about 44 days in 100, so it missed about 0.44 × 8.2 ≈ 3.6 points a year of the rise; its average lag was 3.75 points a year before costs and 4.38 after. The 175 were mostly markets where holding did poorly: in 150 of them holding made less than its 8.2% average (holding was under 8.2 in 520 of all 1,000 markets; when holding earns little or falls, sitting in cash costs little or even helps).

The best of 24, and held-out years

On the lesson's market 2 of the 24 versions beat holding over 2015 to 2021 before costs, and none after costs. On the 1,000 simulated markets 3.9 of the 24 beat holding after costs on average. Before any version was run, 2022 to 2024 were held out (set aside, to be used once). On each market the best of the 24 on 2015 to 2021, after costs, ran once on 2022 to 2024. It stayed best in 47 of the 1,000 simulated markets, against about 42 for a blind draw (one version taken at random: 1,000 ÷ 24), which is within chance (about ±6 either way is noise); these markets have nothing to find, so it is not skill. On 2015 to 2021 the best looked level with holding (−0.03 points a year on average); on 2022 to 2024 it trailed by 4.41.

Formula: how many swings a market with no pattern makes

If every day brings the same kind of move, as likely a rise of any size as a fall of the same size, independently of the other days, and never exactly zero, a close is a swing high (close reading, width n) when the price stays below it for each of the next n days and was below it for each of the n days before. Each side has the chance qn, and the two sides don't affect each other. That qn does not depend on the size of the moves is the Sparre Andersen theorem.

P(swing high) = qn2,   qn = ½ × ¾ × ⅚ × … × (2n − 1) ÷ (2n)
n
the width: the days on each side
qn
the chance the price stays below a given close for each of the next n days, when every day brings the same kind of move, as likely a rise of any size as a fall of the same size, independently, never exactly zero
P(swing high)
the chance a given close is a swing high of width n (close reading), under the same conditions; a swing low has the same chance
Worked example: width 2

q2 = ½ × ¾ = 3/8, not ½ × ½: the price only has to stay below, so down 1% then up 0.5% still counts. P = (3/8)² = 9/64 = 0.141, about 14.1 closes in 100. Across the 1,000 simulated markets, 13.9 in 100 were (width 2, close reading); at width 5, 6.0 against (63/256)² = 6.1.

Holds whenBreaks when

A drift (the lesson's markets rise slowly), calm and wild spells (the size of moves clusters) or prices rounded to cents (ties: equal ±$1 steps would give ¼, not 3/8, at width 2) make it a little off: the lesson's counts sit just under it. Swings read from wicks need other numbers, since a day's high is not its close. A real market needs its own count.

One more worked example

Made-up round numbers

Width 1: a close is a swing high when the close before it and the close after it are both lower. q1 = ½, so P = ½ × ½ = 1/4: in 200 days of a market whose days are independent, each as likely a rise of any size as a fall of the same size, never exactly zero, about 50 swing highs and 50 swing lows. Moving to width 3 gives q3 = ½ × ¾ × ⅚ = 5/16 and P = 25/256, about 19.5 swing highs in the same 200 days: a wider swing is rarer, but with no pattern it still turns up every ten days or so.

Common mistakes

Check yourself

  1. Closes on seven days: 50, 51, 53, 52, 50, 51, 49. Which day is a swing high of width 2 (close reading)?
    Answer

    The third day, 53: above 50 and 51 before it and above 52 and 50 after it. No other day has two lower closes on each side.

  2. In a rising trend, a close falls below the latest swing low. Is it a break of structure or a change of character, and what happens to the trend?
    Answer

    A change of character: the break goes against the trend, so the trend flips to down.

  3. Width 5, close reading, a market whose days are independent, each as likely a rise of any size as a fall of the same size, never exactly zero. About how many closes in 1,000 are swing highs?
    Answer

    q5 = 63/256 = 0.246; squared, 0.0606: about 61 in 1,000.

  4. In the lesson's simulation the best of 24 versions stayed best on held-out years in 47 of 1,000 simulated markets, against about 42 for a blind draw. Does that show market structure works?
    Answer

    No. 47 against 42 is within chance (about ±6 either way is noise), the markets were built with nothing to find, and the best trailed holding by 4.41 points a year on the held-out years on average. A real market needs its own test.

Try it yourself

The rules, written before the code. Daily bars. Swing high of width n: a day whose high (or close) is above that of each of the n days either side; swing low likewise below; known at the close of the nth day after, and used from the next day. A break up: a close (or a high) above the latest known, unused swing high; a break down likewise below the latest swing low; a swing the price breaks is used up. The first break sets the trend; then a break with the trend is a break of structure, against it a change of character (the trend flips). Start-of-move reading: after a break up, the change of character needs the lowest low (close) between the broken level's day and the break, moved again by every later break up; the same with highs after a break down. Both levels broken on one day: nothing changes. The rule: long while the trend is up, cash otherwise, decided at the close, traded at the next open; 0.1% per buy and per sell, or no costs. Compared with buying at the first close and holding, which pays 0.1% once.

Run the script. Every number in this lesson comes from one Python script (below). It imports simmarket.py, the course's simulated market, which must sit in the same folder. Add a width of 3 or a second level reading, and watch the version count and the counts across markets move.

By hand. In a spreadsheet with one row per day (high in C, from row 2), width 2: in row 4, =AND(C4>MAX(C2:C3),C4>MAX(C5:C6)) marks a swing high. Copy it down; the mark is known two rows later.

Written by QuantWright from plain-word definitions of swings, breaks of structure and changes of character, and the rules above. No code from any indicator script or charting platform.

The code behind every number (Python, imports SimMarket, seed 20261109)
Loading…
For the preciseThe lesson's market: SimMarket Market 1, seed 20261109, effect=False (no planted pattern), daily bars built from five-minute bars with bridge="normal", the same daily bars as the Previous day high and low and Opening range lessons. The 1,000 simulated markets: the same generator and setting with seeds 2026221101 to 2026222100. Choosing years: from the close of 5 Jan 2015 to 31 Dec 2021 (6.99 calendar years); held-out: to 31 Dec 2024 (3.00 years). % a year = (the account's growth factor)1 ÷ years − 1. The example days: 2 Jan to 19 May 2017, read on their own (the structure starts with no trend on 2 Jan). The lesson's market: holding 4.38% a year before its cost, 4.36% after (choosing), 10.00% (held-out). Baseline version: −3.05% a year before costs, −3.74% after; lead −7.43 then −8.10, 18th of 24; long on 57.5 days in 100; 25 buys (3.58 a year); held-out lead +0.32, 8th. The best after costs (width 2, close swings, wick breaks, start of the move): lead +1.59 before costs, −1.90 after (16.89 buys a year); held-out lead +1.94, 3rd. The 1,000 simulated markets, ten years: swing highs a year at widths 2, 5, 10: 35.0, 15.4, 7.9 (wicks) and 36.3, 15.6, 7.9 (closes); the share of closes that were swing highs 13.92, 5.98, 3.06 in 100 (rule of thumb 14.06, 6.06, 3.10). Higher highs at width 5 (wicks): 54.46 in 100; higher lows 54.69. Baseline version: 6.17 breaks of structure and 6.15 changes of character a year; after a change of character, 30,217 next breaks went the new way and 30,671 back; trend up on 56.3 days in 100; beat holding before costs in 200, after costs in 175 (choosing), 267 after costs (held-out); average lead −3.75 before costs, −4.38 after, −4.07 held-out. Versions beating holding on the choosing years: 5.05 of 24 on average before costs, 3.90 after; at least one after costs in 492 markets. The best on 2015–2021: start of the move in 526, wick swings in 590, close breaks in 550; beat holding there in 492 and held-out in 263; stayed best in 47; average held-out place 12.17.

Honest notes

Where this comes from