README.mdmung / gann-swing
Gann Swing building
TradingView indicatorW. D. Gann's mechanical swing charts as a TradingView indicator, with a tested Three-Bar Rule on top.
Draws 1-, 2- and 3-bar swing charts by Gann's rules and ignores the noise of inside bars. A Three-Bar Rule overlay marks only the reversals that pass its relevance gates. Pine Script can't be tested locally, so the Three-Bar Rule's defaults were picked with a Python port of the indicator, tested on 15 years of BTC/USD daily bars. It marks reversals worth a look; it is not a trading strategy.
- 1-, 2- and 3-bar swing charts by Gann's rules, inside bars ignored
- Three-Bar Rule with four combinable relevance gates
- Non-repainting by default; the one repainting mode is opt-in and flagged on the chart
- Trend dashboard, swing bar counts and 7 alerts



![Settings of Gann Swing [Mung], Inputs tab, relevance gates: Gate A off; Gate B on with lookback 50 and mode Non-Repaint; Gate C on with ATR Multiple, multiplier 2, ATR period 14 and minimum amplitude 3 %; Gate D off; gate combination Default.](/projects/gann-swing-settings.webp)
- 3swing types: 1-, 2- and 3-bar
- 4combinable relevance gates
- 7built-in alerts
- 1,644setting combinations tested before picking a default
- 15 yrsof BTC/USD daily bars in the test harness
- 17self-tests for the Python port