PROTECTED SOURCE SCRIPT
업데이트됨 TRharmonic ZigZag

TRharmonic Multi-ZigZag — 3-Layer Structure Detector
TRharmonic Multi-ZigZag is a professional-grade recursive zigzag indicator that reveals market structure across three hierarchical layers simultaneously. Unlike traditional single-depth zigzag tools, this indicator builds each layer from the structural pivots of the layer below — capturing both micro price action and macro trend direction in a unified view.
🔹 How It Works
The indicator operates on three recursive levels:
Level 0 (Fast) — Detects base-level swing highs and lows using a configurable lookback window. This layer captures the finest price structure and reacts quickly to new pivots.
Level 1 (Medium) — Automatically derived from Level 0's significant pivots (Higher Highs and Lower Lows). Filters out noise and reveals intermediate market structure.
Level 2 (Trend) — Built from Level 1's structural breakouts, showing only the dominant trend-level swings. This is the "big picture" layer.
Each higher level inherits only the most significant pivots from the level below — HH (Higher High) and LL (Lower Low) pivots propagate upward, while LH (Lower High) and HL (Higher Low) pivots are buffered and only promoted when structurally necessary.
🔹 Pivot Classification
Every pivot is automatically classified into one of four categories:
HH (Higher High) — Price made a new high above the previous high → Bullish continuation
LL (Lower Low) — Price made a new low below the previous low → Bearish continuation
LH (Lower High) — Price failed to exceed the previous high → Potential weakness
HL (Higher Low) — Price held above the previous low → Potential strength
These labels appear directly on the chart with color-coded markers for instant visual recognition.
🔹 Key Features
✅ 3 recursive zigzag layers with independent depth settings
✅ Real-time HH/HL/LH/LL classification on every pivot
✅ Fully customizable colors, line widths, and label visibility per layer
✅ Toggle each layer on/off independently
✅ Professional stats table showing pivot count, last direction, and price per layer
✅ Zero-lag design — no repainting on confirmed bars
✅ Works on all instruments and timeframes (5min+)
🔹 Use Cases
Trend Identification: Level 2 shows the dominant trend; consecutive HH+HL = uptrend, LH+LL = downtrend
Structure Break Detection: When Level 1 prints an LL after a series of HH = potential trend reversal
Multi-Timeframe in Single Chart: Three structural layers eliminate the need to switch between timeframes
🔹 Settings
Parameter Default Description
Fast Depth 7 Level 0 lookback — more pivots, faster reaction
Medium Depth 13 Level 1 — standard market structures
Trend Depth 34 Level 2 — major trend waves only
Max Pivots 200 Maximum stored pivots per level
🔹 Recommended Approach
Start with default settings. Use Level 0 for scalping entries, Level 1 for swing trade structure, and Level 2 for trend direction bias. When all three levels align (e.g., all showing HH), you have strong trend confluence.
⚠️ This indicator is a structural analysis tool. It does not generate buy/sell signals. Always combine with your own analysis and risk management.
TRharmonic Multi-ZigZag is a professional-grade recursive zigzag indicator that reveals market structure across three hierarchical layers simultaneously. Unlike traditional single-depth zigzag tools, this indicator builds each layer from the structural pivots of the layer below — capturing both micro price action and macro trend direction in a unified view.
🔹 How It Works
The indicator operates on three recursive levels:
Level 0 (Fast) — Detects base-level swing highs and lows using a configurable lookback window. This layer captures the finest price structure and reacts quickly to new pivots.
Level 1 (Medium) — Automatically derived from Level 0's significant pivots (Higher Highs and Lower Lows). Filters out noise and reveals intermediate market structure.
Level 2 (Trend) — Built from Level 1's structural breakouts, showing only the dominant trend-level swings. This is the "big picture" layer.
Each higher level inherits only the most significant pivots from the level below — HH (Higher High) and LL (Lower Low) pivots propagate upward, while LH (Lower High) and HL (Higher Low) pivots are buffered and only promoted when structurally necessary.
🔹 Pivot Classification
Every pivot is automatically classified into one of four categories:
HH (Higher High) — Price made a new high above the previous high → Bullish continuation
LL (Lower Low) — Price made a new low below the previous low → Bearish continuation
LH (Lower High) — Price failed to exceed the previous high → Potential weakness
HL (Higher Low) — Price held above the previous low → Potential strength
These labels appear directly on the chart with color-coded markers for instant visual recognition.
🔹 Key Features
✅ 3 recursive zigzag layers with independent depth settings
✅ Real-time HH/HL/LH/LL classification on every pivot
✅ Fully customizable colors, line widths, and label visibility per layer
✅ Toggle each layer on/off independently
✅ Professional stats table showing pivot count, last direction, and price per layer
✅ Zero-lag design — no repainting on confirmed bars
✅ Works on all instruments and timeframes (5min+)
🔹 Use Cases
Trend Identification: Level 2 shows the dominant trend; consecutive HH+HL = uptrend, LH+LL = downtrend
Structure Break Detection: When Level 1 prints an LL after a series of HH = potential trend reversal
Multi-Timeframe in Single Chart: Three structural layers eliminate the need to switch between timeframes
🔹 Settings
Parameter Default Description
Fast Depth 7 Level 0 lookback — more pivots, faster reaction
Medium Depth 13 Level 1 — standard market structures
Trend Depth 34 Level 2 — major trend waves only
Max Pivots 200 Maximum stored pivots per level
🔹 Recommended Approach
Start with default settings. Use Level 0 for scalping entries, Level 1 for swing trade structure, and Level 2 for trend direction bias. When all three levels align (e.g., all showing HH), you have strong trend confluence.
⚠️ This indicator is a structural analysis tool. It does not generate buy/sell signals. Always combine with your own analysis and risk management.
릴리즈 노트
Added MAX_LOOKBACK constraint to prevent historical buffer overflow errors when accessing pivots beyond the 5000-bar limit보호된 스크립트입니다
이 스크립트는 비공개 소스로 게시됩니다. 하지만 이를 자유롭게 제한 없이 사용할 수 있습니다 – 자세한 내용은 여기에서 확인하세요.
TRharmonic
면책사항
해당 정보와 게시물은 금융, 투자, 트레이딩 또는 기타 유형의 조언이나 권장 사항으로 간주되지 않으며, 트레이딩뷰에서 제공하거나 보증하는 것이 아닙니다. 자세한 내용은 이용 약관을 참조하세요.
보호된 스크립트입니다
이 스크립트는 비공개 소스로 게시됩니다. 하지만 이를 자유롭게 제한 없이 사용할 수 있습니다 – 자세한 내용은 여기에서 확인하세요.
TRharmonic
면책사항
해당 정보와 게시물은 금융, 투자, 트레이딩 또는 기타 유형의 조언이나 권장 사항으로 간주되지 않으며, 트레이딩뷰에서 제공하거나 보증하는 것이 아닙니다. 자세한 내용은 이용 약관을 참조하세요.