Skip to content
All library documents

Automatic Fibonacci and Gann Retracement and Fan Levels

Article TradingView scripts

Summary

This indicator detects swing highs and lows from sequences of candle direction and draws Fibonacci and Gann retracement or fan lines between selected extrema. Fibonacci retracements use standard fractional levels, while Gann retracements use a separate set of proportional levels. Fan lines project from swing points using ratio-based slopes adjusted for the chart’s price-to-bar scale, which is estimated from recent swing movements.

The script lets users choose which line sets to display, their styles, labels, and whether recent retracement lines extend across the chart. It marks extrema as they are identified and maintains line sets around evolving pivots. These levels are charting references rather than a tested trading strategy: the document offers no entry or exit rules, backtest, or evidence that the projected levels reliably act as support or resistance. Pivot detection and chart scaling affect where the lines appear.

Key ideas

  • The indicator identifies candidate swing extrema from changes in candle direction and local highs or lows.
  • Fibonacci retracement levels and fan lines are drawn from detected pivots.
  • Gann retracements and fans use distinct ratios to project price levels and slopes.
  • Fan slopes are adjusted using a chart scale estimated from swing price changes over time.
  • The document describes a visualization tool without tested trading rules or performance evidence.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.