For the Record

Swings · Leg counter · thinkorswim · Open source · Live

AsksIs this pullback the trend breathing, or breaking?

Every leg gets entered into the record. This study follows changes between upward and downward swing states, marks turns with numbered bubbles, and highlights selected failed-extension conditions in magenta. It makes a sequence of pullbacks easier to count without requiring you to label every turn by hand.

For the Record on an ES 15-minute chart: numbered swing-leg bubbles through a selloff and recovery, with failed-break turns in magenta For the Record on an ES 1-hour chart: leg counts tracking a full week of swings with the status label reading the current swing state

Download the thinkScript →

Get started

  1. Install the downloaded thinkScript through Charts → Studies → Edit Studies → Create in thinkorswim desktop and apply it to the price chart.
  2. Follow the numbered bubbles through a completed stretch of history before interpreting the latest turn. Read the separate up-leg and down-leg counts in the status label.
  3. Check failTicks for the instrument you are viewing. The tolerance is expressed in the instrument's ticks rather than a fixed number of price points.
  4. Use the bubble-offset controls if labels crowd candles. Optional arrows can be enabled when you want a second visual marker at turns.

How to read it

A local swing stateAn upward state can switch down when a bar makes a lower low; a downward state can switch up when a bar makes a higher high. This is a bar-by-bar structure model, not an independent estimate of the market's longer-term trend.

Why the numbers restartUp-leg counting restarts when a new turn establishes a lower reference low. Down-leg counting restarts when a new turn establishes a higher reference high. Otherwise the respective count advances.

The magenta objectionMagenta appears at selected turns when the count and failed-extension test agree. The test uses the configured tick tolerance and stored pivot references; read it together with the actual candles and surrounding structure.

Know the limits

A second leg or magenta bubble does not by itself establish a valid reversal. The study counts its own rule-defined sequence.

Current-bar highs and lows can change the active swing state before the candle finishes.

An outside bar can break both the previous high and low. The state machine resolves that bar according to its existing state, so counts may differ from a discretionary zigzag count.

Open source, no email wall. Read the code, test it on your own chart, and keep it. Explore all 20 free tools.

One tool reads one part of the market.
MIZAN grades the whole setup.

For the Record gives you a focused read. The paid MIZAN engine runs on TradingView and combines seven proprietary validation layers, a 0–100 evidence score, and risk calibration to qualify or block setups.

Start your 7-day free trial

From $99.99/month after the trial · Cancel anytime · Access within 24 hours

Compare Core and Institutional →