Skip to content
StatePath
Tool Atlasmarket.fibonacci_anchor

Tool

Fibonacci Anchor

market.fibonacci_anchor

MarketFibonacci

Inputs

pivotsEvent list

A stream of swing pivots (highs and lows), normally fed from a zigzag or leg tool; the anchor leg is chosen from these turning points.

Outputs

Bundle (untagged)

A Fibonacci retracement/extension bundle — each level (0.0, 0.236, 0.382, 0.5, 0.618, 0.786, 1.0 and extensions) carried as a price you can tap individually to test for touches, bounces, or breaks.

Fibonacci Anchor selects the one price swing (a “leg”) that every Fibonacci calculation should hang off, and emits that leg plus its two real pivot endpoints. Wire it into Fibonacci Retracement, OTE, Expansion/Projection or Cluster so they all measure the SAME swing.

Fibonacci Anchor overview diagramfib.0fib.236fib.382fib.5fib.618fib.1

How it works

It reads swing pivots from the connected zigzag input, picks one leg according to leg_direction and leg_select, and emits that leg (plus its start and end pivots) unchanged — it computes no Fibonacci levels itself; the downstream retracement / OTE / projection nodes do the ratio math on the leg it hands them. The mode setting decides whether it anchors to the last fully confirmed leg or re-anchors live to the leg still forming.

Modes

Mode options

Confirmed legconfirmed

Anchors the levels only to a leg whose swing high and low are both finalized, so the lines stop moving once the leg completes.

Confirmed leg diagramfib.0fib.236fib.382fib.5fib.618fib.1

When to use: The stable default — use it when you want levels that never shift under your feet during a backtest or live trade.

Latest leglatest

Re-anchors to the most recent leg as it forms, so the levels move and re-draw while the newest swing is still developing.

Latest leg diagramfib.0fib.382fib.5fib.1

When to use: When you want the freshest possible levels and accept that they repaint until the leg confirms.

Leg direction options

Up legup

Forces the anchor onto an upward leg (swing low up to swing high), so 0% sits at the high and 100% at the low — the classic long-side retracement layout.

Up leg diagramfib.leg.startfib.leg.end

When to use: When you only want to map pullbacks inside up-moves.

Down legdown

Forces the anchor onto a downward leg (swing high down to swing low), so 0% sits at the low and 100% at the high — the short-side retracement layout.

Down leg diagramfib.leg.startfib.leg.end

When to use: When you only want to map pullbacks inside down-moves.

Auto directionauto

Lets the tool pick the leg direction on its own from the latest swing structure, anchoring up or down to match the most recent move.

Auto direction diagramzz.lowzz.highzz.lowzz.highzz.low

When to use: The hands-off choice when you want levels on whichever way the market just swung.

Leg select options

Impulse legimpulse

Anchors to the strong impulse leg (the dominant directional swing), spreading retracement levels across the move you expect price to pull back into.

Impulse leg diagramfib.0fib.236fib.382fib.5fib.618fib.1

When to use: Standard Fibonacci retracement workflow — measure the impulse, wait for the pullback into 0.5/0.618.

Retrace legretrace

Anchors to the counter-trend retrace leg instead, projecting extension targets for where the next impulse may run.

Retrace leg diagramfib.0fib.5fib.1fib.1272

When to use: Projection / target work — measure the pullback to extend levels in the trend direction.

Configuration

modeenum

Whether the levels anchor to the last fully confirmed leg (stable, non-repainting) or re-anchor live to the leg still forming (fresher but repaints).

Choices:confirmedlatest
leg_directionenum

Which leg orientation to anchor on: 'up' (low→high), 'down' (high→low), or 'auto' to follow the latest swing direction.

Choices:updownauto
leg_selectenum

Which leg of the swing to measure: 'impulse' for the dominant directional move (retracements) or 'retrace' for the counter-trend leg (extensions/projections).

Choices:impulseretrace
swing_lookbackscalar

How many bars back the tool scans for swing pivots when choosing the leg; larger values reach for bigger, slower swings.

min_leg_pointsscalar

The smallest leg size, in points, that qualifies for anchoring — legs shorter than this are ignored so tiny wiggles don't draw levels.

point_valuescalar

The price size of one point for this symbol, used to convert min_leg_points into an actual price distance (e.g. 0.0001 for a 5-digit FX pair).

Connects to

Reads from
Feeds into

Examples

  • Feed a zigzag's pivots in, pick leg_select 'impulse' with leg_direction 'auto', then read interpretor.fibonacci_level to fire when price reaches the 0.618 retracement.
  • Use leg_select 'retrace' to project extension targets and gate take-profit logic at the 1.272 / 1.618 levels.

Common mistakes

  • Leaving mode on 'latest' and trusting the levels for entries — they repaint until the leg confirms, so backtests can look better than reality.
  • Setting min_leg_points too small so the tool anchors to insignificant wiggles and draws levels on noise.

See also