OPEN-SOURCE SCRIPT
HMA 34 Dual-Fractal Projections - Vdubus

Vdubus MacD Divergence Trend Break Signal Generator :Here:-

HMA 18 Dual-Fractal Projections
Overview
The HMA 18 Dual-Fractal Projections is a technical analysis tool designed to identify market structure and potential breakout patterns by analyzing the pivots of a Hull Moving Average (HMA).
Unlike standard trendline indicators that struggle to balance "big picture" trends with immediate price action, this indicator utilizes a Dual-Fractal approach. It simultaneously calculates two separate timelines—Macro and Micro—to visualize both the dominant channel and the developing chart patterns (such as wedges or triangles) in real-time.
Visual Guide
The indicator plots three key elements on the main chart:
The HMA Line (Blue): A smooth, fast-acting moving average (default length 34) that serves as the baseline for all calculations.
Macro Structure (Solid, Thick Lines):
Red (Solid): Major Resistance.
Green (Solid): Major Support.
Purpose: Identifies the long-term trend channel. These lines react slowly and filter out noise.
Micro Structure (Dashed, Thin Lines):
Red (Dashed): Immediate Resistance.
Green (Dashed): Immediate Support.
Purpose: Identifies the short-term market structure. These lines react quickly to show forming wedges, triangles, or flags.
How It Works
The indicator applies a "Pivot High/Low" algorithm directly to the HMA data rather than raw price data. This filters out candle wicks and volatility, ensuring lines are drawn based on established momentum shifts.
Layer 1 (Macro): Uses a large "Lookback" period (default 44 bars) to find significant peaks and valleys. It connects the most recent major pivot to the previous one, projecting a line forward to show where the major trend channel lies.
Layer 2 (Micro): Uses a small "Lookback" period (default 10 bars) to find local peaks and valleys. This allows you to see how price is behaving within the larger channel.
Settings & Configuration
HMA Settings
HMA Length: The length of the Hull Moving Average.
Default: 34 (Matches the "visually pleasing" setting from recent testing).
Note: Set to 18 for a faster, more reactive baseline (scalping).
Layer 1: Macro (Big Channel)
Macro Lookback: Determines how many bars must pass before a peak is confirmed.
Default: 44. High values find broad, established channels.
Max Macro Lines: How many historical lines to keep on the chart.
Default: 1 (Keeps the chart clean, showing only the current structure).
Extend Macro Lines: Projects the lines infinitely to the right to predict future support/resistance zones.
Layer 2: Micro (Current Pattern)
Micro Lookback: A lower sensitivity setting to catch immediate structure.
Default: 10. Low values will pinpoint the exact boundaries of small wedges or flags forming right now.
Trading Strategy & Interpretation
1. The "Squeeze" (Wedge Identification) This is the primary use case.
Look for scenarios where the Macro Lines (Solid) are wide/parallel, but the Micro Lines (Dashed) are rapidly converging (pointing towards each other).
This indicates that while the main trend is intact, momentum is compressing. A breakout is imminent where the dashed lines intersect.
2. Trend Channels
When both Solid and Dashed lines are roughly parallel and sloping in the same direction, the trend is healthy and strong. Price is respecting both the short-term and long-term momentum.
3. Divergence / Early Reversal Warning
If the Macro Line is sloping UP, but the Micro Line starts sloping DOWN (crossing inside), it indicates a loss of momentum and a potential reversal before the price actually breaks the major trendline.
===========================================================================
2. Micro/Macro Cross Alert
A new input, Enable Micro/Macro Cross Alert, has been added under the "Alerts & Features" section.
This alert condition is triggered when the momentum of the Micro Structure exceeds the momentum of the Macro Structure, which is a high-probability signal for a breakout:
Bullish Alert: The Micro High (dashed red line) crosses above the Macro High (solid red line).
Bearish Alert: The Micro Low (dashed green line) crosses below the Macro Low (solid green line).
To set up the actual alert on your chart:
Right-click on the chart.
Select "Add alert on HMA 34 Dual-Fractal Projections".
In the Condition dropdown, select the indicator's name.
For the main alert criteria, choose "Any alert()".
Select your preferred alert actions (e.g., notification, email).

HMA 18 Dual-Fractal Projections
Overview
The HMA 18 Dual-Fractal Projections is a technical analysis tool designed to identify market structure and potential breakout patterns by analyzing the pivots of a Hull Moving Average (HMA).
Unlike standard trendline indicators that struggle to balance "big picture" trends with immediate price action, this indicator utilizes a Dual-Fractal approach. It simultaneously calculates two separate timelines—Macro and Micro—to visualize both the dominant channel and the developing chart patterns (such as wedges or triangles) in real-time.
Visual Guide
The indicator plots three key elements on the main chart:
The HMA Line (Blue): A smooth, fast-acting moving average (default length 34) that serves as the baseline for all calculations.
Macro Structure (Solid, Thick Lines):
Red (Solid): Major Resistance.
Green (Solid): Major Support.
Purpose: Identifies the long-term trend channel. These lines react slowly and filter out noise.
Micro Structure (Dashed, Thin Lines):
Red (Dashed): Immediate Resistance.
Green (Dashed): Immediate Support.
Purpose: Identifies the short-term market structure. These lines react quickly to show forming wedges, triangles, or flags.
How It Works
The indicator applies a "Pivot High/Low" algorithm directly to the HMA data rather than raw price data. This filters out candle wicks and volatility, ensuring lines are drawn based on established momentum shifts.
Layer 1 (Macro): Uses a large "Lookback" period (default 44 bars) to find significant peaks and valleys. It connects the most recent major pivot to the previous one, projecting a line forward to show where the major trend channel lies.
Layer 2 (Micro): Uses a small "Lookback" period (default 10 bars) to find local peaks and valleys. This allows you to see how price is behaving within the larger channel.
Settings & Configuration
HMA Settings
HMA Length: The length of the Hull Moving Average.
Default: 34 (Matches the "visually pleasing" setting from recent testing).
Note: Set to 18 for a faster, more reactive baseline (scalping).
Layer 1: Macro (Big Channel)
Macro Lookback: Determines how many bars must pass before a peak is confirmed.
Default: 44. High values find broad, established channels.
Max Macro Lines: How many historical lines to keep on the chart.
Default: 1 (Keeps the chart clean, showing only the current structure).
Extend Macro Lines: Projects the lines infinitely to the right to predict future support/resistance zones.
Layer 2: Micro (Current Pattern)
Micro Lookback: A lower sensitivity setting to catch immediate structure.
Default: 10. Low values will pinpoint the exact boundaries of small wedges or flags forming right now.
Trading Strategy & Interpretation
1. The "Squeeze" (Wedge Identification) This is the primary use case.
Look for scenarios where the Macro Lines (Solid) are wide/parallel, but the Micro Lines (Dashed) are rapidly converging (pointing towards each other).
This indicates that while the main trend is intact, momentum is compressing. A breakout is imminent where the dashed lines intersect.
2. Trend Channels
When both Solid and Dashed lines are roughly parallel and sloping in the same direction, the trend is healthy and strong. Price is respecting both the short-term and long-term momentum.
3. Divergence / Early Reversal Warning
If the Macro Line is sloping UP, but the Micro Line starts sloping DOWN (crossing inside), it indicates a loss of momentum and a potential reversal before the price actually breaks the major trendline.
===========================================================================
2. Micro/Macro Cross Alert
A new input, Enable Micro/Macro Cross Alert, has been added under the "Alerts & Features" section.
This alert condition is triggered when the momentum of the Micro Structure exceeds the momentum of the Macro Structure, which is a high-probability signal for a breakout:
Bullish Alert: The Micro High (dashed red line) crosses above the Macro High (solid red line).
Bearish Alert: The Micro Low (dashed green line) crosses below the Macro Low (solid green line).
To set up the actual alert on your chart:
Right-click on the chart.
Select "Add alert on HMA 34 Dual-Fractal Projections".
In the Condition dropdown, select the indicator's name.
For the main alert criteria, choose "Any alert()".
Select your preferred alert actions (e.g., notification, email).
开源脚本
秉承TradingView的精神,该脚本的作者将其开源,以便交易者可以查看和验证其功能。向作者致敬!您可以免费使用该脚本,但请记住,重新发布代码须遵守我们的网站规则。
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。
开源脚本
秉承TradingView的精神,该脚本的作者将其开源,以便交易者可以查看和验证其功能。向作者致敬!您可以免费使用该脚本,但请记住,重新发布代码须遵守我们的网站规则。
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。