OPEN-SOURCE SCRIPT
Harmonic Pulse | XABCD Fibonacci Pattern Strategy

Harmonic Pulse scans zigzag swing pivots for the four classic Fibonacci harmonic patterns — Gartley, Bat, Butterfly, and Crab — and trades the reversal expected at the D-point completion. Rather than eyeballing X-A-B-C-D on the chart, it measures the AB/XA, BC/AB, CD/BC, and XD/XA leg ratios against each pattern's textbook Fibonacci targets and enters when enough of them line up, with a stop beyond the X point and a fixed reward:risk target.
Features
Tips
Warnings
Features
- Pivot-based zigzag (adjustable Pivot Length) drives the whole pattern search
- Detects Gartley, Bat, Butterfly, and Crab — toggle any pattern on/off individually
- Partial-match scoring: choose how many of the 4 ratios must align (2–4) to fire a trade, instead of an all-or-nothing match
- Adjustable Ratio Tolerance to control how strictly price has to hit each Fibonacci level
- ATR-based stop beyond the X point, fixed Reward:Risk target
- Trade direction filter (Both / Long Only / Short Only) and cooldown between entries
- Every matched pattern is drawn on the chart (X-A-B-C-D lines) with its match score and key ratios labeled
- Plain zigzag pivot markers, independent of pattern matching, for a quick visual sanity check
- Live status readout: pivots stored, patterns found, open and closed trade counts
Tips
- Start on the Daily timeframe on liquid, volatile large caps (NVDA, TSLA, AMD, SPY) — harmonic trading is a swing-timeframe approach and needs room for real structure to form
- If nothing's triggering, watch the zigzag pivot markers first — if those aren't appearing, it's a chart/history issue, not a pattern-matching issue
- Treat Ratio Tolerance and Minimum Matching Ratios as a linked pair: loosen both together for more trades, tighten both together for higher-conviction ones
- Disable patterns you don't want to trade (e.g. turn off Crab if you only trust the tighter Gartley/Bat completions) rather than leaving all four on by default
- Backtest across multiple symbols and date ranges before trusting any single result — harmonic setups are infrequent, so one chart's backtest is a small sample
Warnings
- Pivot confirmation is inherently backward-looking — a pattern only confirms Pivot Length bars after the actual turn, so live behavior will lag what you see in a backtest
- Harmonic pattern trading is a discretionary, pattern-recognition approach without a rigorous statistical basis — treat this as a structured way to find candidate setups, not a proven edge
- Loosening Ratio Tolerance or lowering Minimum Matching Ratios increases trade frequency but degrades how closely price actually respects the pattern — more trades isn't automatically better
- Backtest results don't include realistic slippage on stops/gaps through targets; verify these assumptions before considering live use
- Not financial advice — this is a tool for research and idea generation, not a signal to act on directly
Open-source Skript
Ganz im Sinne von TradingView hat dieser Autor sein/ihr Script als Open-Source veröffentlicht. Auf diese Weise können nun auch andere Trader das Script rezensieren und die Funktionalität überprüfen. Vielen Dank an den Autor! Sie können das Script kostenlos verwenden, aber eine Wiederveröffentlichung des Codes unterliegt unseren Hausregeln.
Haftungsausschluss
Die Informationen und Veröffentlichungen sind nicht als Finanz-, Anlage-, Handels- oder andere Arten von Ratschlägen oder Empfehlungen gedacht, die von TradingView bereitgestellt oder gebilligt werden, und stellen diese nicht dar. Lesen Sie mehr in den Nutzungsbedingungen.
Open-source Skript
Ganz im Sinne von TradingView hat dieser Autor sein/ihr Script als Open-Source veröffentlicht. Auf diese Weise können nun auch andere Trader das Script rezensieren und die Funktionalität überprüfen. Vielen Dank an den Autor! Sie können das Script kostenlos verwenden, aber eine Wiederveröffentlichung des Codes unterliegt unseren Hausregeln.
Haftungsausschluss
Die Informationen und Veröffentlichungen sind nicht als Finanz-, Anlage-, Handels- oder andere Arten von Ratschlägen oder Empfehlungen gedacht, die von TradingView bereitgestellt oder gebilligt werden, und stellen diese nicht dar. Lesen Sie mehr in den Nutzungsbedingungen.