OPEN-SOURCE SCRIPT

Harmonic Assistant(XABCD)

1 673
**Harmonic Assistant (XABCD)**


**Overview**
Trading harmonic patterns can often be a highly subjective, tedious, and visually cluttered process. The **Harmonic Assistant Pro** is designed to eliminate the guesswork. It is an advanced, fully automated XABCD pattern detection engine that not only finds high-probability setups (Gartley, Bat, Butterfly, Crab) but also acts as a live trading assistant, explaining market geometry to you in real-time.

Unlike standard harmonic indicators that cover your screen in messy lines, this script introduces **Smart Label Placement** and a dynamic **Live Commentary Panel**, keeping your charts exceptionally clean and your mind focused on the trade execution.

**Key Features & Innovations**

* 🦇 **Automated Classic Patterns:** Instantly detects Bullish and Bearish Gartley, Bat, Butterfly, and Crab formations using a highly optimized, lag-free ZigZag engine.
* 🧠 **Live Commentary Panel:** The indicator speaks to you. Instead of just displaying raw math, the HUD translates ratios into actionable insights. It will tell you: *"Bat Candidate: Awaiting D at 0.886"* or *"Invalid: B point broke X origin"*.
* 📐 **Complete Auto-Fibonacci:** Once an XA leg is established, the script automatically draws a complete set of Fibonacci retracement and extension lines (from 0.0 all the way to 4.236). This allows you to visually anticipate where the D point (target) will land before it happens.
* 🛡️ **Smart Invalidation & Trend Filter:** The script knows when a pattern is mathematically dead. If the B point breaks the X origin, or if the price goes parabolic (extreme extension), it instantly invalidates the pattern to protect you from false signals.
* ✅ **Actionable Trade Plans:** Upon pattern confirmation, the script dynamically draws a Potential Reversal Zone (PRZ) box, precise Take Profit levels (TP1, TP2), and a strict Stop Loss (SL) line based on classical harmonic rules.

**How to Read the Indicator**
1. **Yellow Phase (Preparation):** The lines and the info panel are yellow. The script has found the X, A, B, and C points and is waiting for the D point to hit the Fibonacci target. Read the panel to see which pattern is forming.
2. **Green/Red Phase (Execution):** The target is hit! The panel turns Green (Bullish) or Red (Bearish). The PRZ box and TP/SL lines appear. This is your signal to look for reversal price action.

**Customizable Settings**
* **Wave Size (Pivot):** Adjusts the sensitivity of the ZigZag engine. Use lower values (e.g., 5-10) for scalp setups and higher values (e.g., 30-50) for macro swing trading.
* **Tolerance (%):** Financial markets are messy. The tolerance setting (default 10%) allows the script to catch valid patterns even if they miss the exact Fibonacci ratio by a few fractions.
* **Language:** Fully supports both English and Turkish interfaces.
* **Visual Toggles:** Turn the Auto-Fibo lines or the "Waiting" (Yellow) lines on/off to suit your visual preference.

*Disclaimer: Harmonic patterns represent high-probability reversal zones, not absolute guarantees. Always use the provided Stop Loss level and practice proper risk management.*

คำจำกัดสิทธิ์ความรับผิดชอบ

ข้อมูลและบทความไม่ได้มีวัตถุประสงค์เพื่อก่อให้เกิดกิจกรรมทางการเงิน, การลงทุน, การซื้อขาย, ข้อเสนอแนะ หรือคำแนะนำประเภทอื่น ๆ ที่ให้หรือรับรองโดย TradingView อ่านเพิ่มเติมใน ข้อกำหนดการใช้งาน