PROTECTED SOURCE SCRIPT
EMA Fractal Divergence

EMA Fractal Divergence
Comprehensive Trading System: Trend, Structure & Momentum
1. Overview
EMA Fractal Divergence is an all-in-one technical analysis tool designed to provide a complete market context at a glance. It eliminates the need for multiple indicators by fusing three critical trading concepts into a single chart overlay:
Trend: EMA Ribbon for trend direction and strength.
Structure: Swing Highs/Lows (Fractals) for Support & Resistance.
Momentum: RSI Divergence for potential reversal setups.
2. Key Features & Components
A. The EMA Ribbon (Trend)
Configuration: Displays four Exponential Moving Averages (21, 55, 100, 200).
EMA 21 (Orange): Represents the short-term trend/fast line.
EMA 55/100/200 (Dark Gray): Represent medium to long-term trends.
Visual Logic:
Solid Colors: Default setting for clear visibility.
Dynamic Transparency (Optional): Can be enabled in settings. If enabled, lines become semi-transparent when price is below them to reduce visual clutter in downtrends.
Dashboard (Top Right):
Shows the real-time position of price relative to each EMA (Above ▲ / Below ▼).
Displays the % distance between price and EMAs.
Overall Status: Summarizes the trend (e.g., "Strong Bullish", "Range", "Weak").
B. Fractal Structure (Support & Resistance)
Fractal Lines (Purple): Connects significant Swing Highs and Swing Lows.
Helps visualize market structure (Higher Highs, Lower Lows).
Acts as dynamic support and resistance levels.
Key Level Dashboard (Bottom Right):
Displays the exact price of the most recent Previous High and Previous Low.
Crucial for breakout or breakdown trading strategies.
C. RSI Divergence (Momentum)
Signals: Detects discrepancies between Price action and RSI momentum.
Green Triangle (Below Bar): Bullish Divergence (Potential Long).
Red Triangle (Above Bar): Bearish Divergence (Potential Short).
Visual Aid: Draws a line connecting the pivot points on the price chart to visualize the divergence clearly.
Optimized Filtering:
Zone Filter (Disabled by Default): Can be enabled to only show signals when RSI is Overbought (>65) or Oversold (<35).
Candle Filter: Bullish signals only appear on Green candles; Bearish signals only on Red candles.
3. Settings Guide
EMA Settings: Toggle the dashboard, adjust line width, or enable "Dynamic Transparency".
Fractal Settings: Show/Hide lines, change the default Purple color.
RSI Settings: Adjust RSI Length (Default 14) or Pivot Lookback.
Alerts: Set alerts for EMA crossovers or Divergence signals in the TradingView Alert menu.
4. How to Trade (Strategy Example)
Identify Trend: Check the EMA Dashboard. Is the status "Strong Bullish"? Are prices above the Orange EMA 21?
Check Structure: Look at the Purple Fractal lines. Is price making higher highs? Wait for a pullback to a previous Fractal Low (Support).
Confirm Entry: Look for a Green Bullish Divergence triangle or a bounce off the EMA 55/100.
🇨🇳 中文版:指标使用说明书
EMA Fractal Divergence (趋势结构融合指标)
集趋势、结构、动能于一体的综合交易系统
1. 指标概述
EMA Fractal Divergence 是一个旨在解决“图表杂乱”问题的全能型指标。它将交易中最重要的三个维度融合在一个脚本中,帮助交易者一眼看清市场全貌:
趋势 (Trend): 通过 EMA 均线组判断方向。
结构 (Structure): 通过分型 (Fractal) 识别关键支撑阻力位。
动能 (Momentum): 通过 RSI 背离捕捉反转信号。
2. 核心功能详解
A. EMA 均线组 (趋势判断)
均线配置: 包含 4 条指数移动平均线 (21, 55, 100, 200)。
EMA 21 (橙色): 短期趋势线,用于判断短期强弱。
EMA 55/100/200 (深灰色): 中长期趋势线,作为重要支撑/阻力带。
显示逻辑:
纯色显示: 默认状态,清晰明了。
动态透明度 (可选): 在设置中开启。开启后,当价格跌破均线时,均线会变淡(半透明),从而在下跌趋势中减少视觉干扰。
趋势面板 (右上角):
实时显示当前价格在各条均线的上方还是下方。
显示价格距离均线的乖离率 (%)。
综合状态: 自动判断当前是“强势”、“蓄势”、“震荡”还是“弱势”。
B. 前高前低分型 (市场结构)
分型连线 (紫色): 自动连接关键的波段高点和低点。
用于识别市场结构(如更高的高点 HH,更低的低点 LL)。
连线处通常是潜在的支撑或压力位。
价格面板 (右下角):
实时显示最近一个前高 (Previous High) 和 前低 (Previous Low) 的具体价格。
辅助判断突破进场点或止损点。
C. RSI 背离 (动能反转)
信号系统: 自动检测价格与 RSI 指标的背离情况。
绿色三角 (K线下): 看涨背离 (Bullish Div),潜在做多信号。
红色三角 (K线上): 看跌背离 (Bearish Div),潜在做空信号。
辅助连线: 出现信号时,会在主图画出对应的价格连线,方便复盘。
智能过滤:
区域过滤 (默认关闭): 旨在捕捉更多机会。如需更保守,可在设置中开启,仅检测超买(>65)/超卖(<35)区域的背离。
K线形态过滤: 看涨信号必须收阳线,看跌信号必须收阴线,提高胜率。
3. 设置指南
EMA设置: 可调整线条宽度、颜色,或开启/关闭“动态透明度”。
分型设置: 可自定义连线颜色(默认紫色)和粗细。
RSI背离: 可调整 RSI 长度(默认14)或 Pivot 回溯周期。
警报: 支持添加 TradingView 警报,包括“突破均线”或“发现背离”等条件。
4. 交易策略示例 (共振交易法)
顺势: 观察右上角面板,确认处于“强势”或均线向上发散(价格在橙色线之上)。
找位: 等待价格回调至紫色分型线(前低支撑)或 灰色 EMA 均线附近。
触发: 等待出现 绿色看涨背离三角,或价格收盘重新站上橙色 EMA 21,即可入场。
Comprehensive Trading System: Trend, Structure & Momentum
1. Overview
EMA Fractal Divergence is an all-in-one technical analysis tool designed to provide a complete market context at a glance. It eliminates the need for multiple indicators by fusing three critical trading concepts into a single chart overlay:
Trend: EMA Ribbon for trend direction and strength.
Structure: Swing Highs/Lows (Fractals) for Support & Resistance.
Momentum: RSI Divergence for potential reversal setups.
2. Key Features & Components
A. The EMA Ribbon (Trend)
Configuration: Displays four Exponential Moving Averages (21, 55, 100, 200).
EMA 21 (Orange): Represents the short-term trend/fast line.
EMA 55/100/200 (Dark Gray): Represent medium to long-term trends.
Visual Logic:
Solid Colors: Default setting for clear visibility.
Dynamic Transparency (Optional): Can be enabled in settings. If enabled, lines become semi-transparent when price is below them to reduce visual clutter in downtrends.
Dashboard (Top Right):
Shows the real-time position of price relative to each EMA (Above ▲ / Below ▼).
Displays the % distance between price and EMAs.
Overall Status: Summarizes the trend (e.g., "Strong Bullish", "Range", "Weak").
B. Fractal Structure (Support & Resistance)
Fractal Lines (Purple): Connects significant Swing Highs and Swing Lows.
Helps visualize market structure (Higher Highs, Lower Lows).
Acts as dynamic support and resistance levels.
Key Level Dashboard (Bottom Right):
Displays the exact price of the most recent Previous High and Previous Low.
Crucial for breakout or breakdown trading strategies.
C. RSI Divergence (Momentum)
Signals: Detects discrepancies between Price action and RSI momentum.
Green Triangle (Below Bar): Bullish Divergence (Potential Long).
Red Triangle (Above Bar): Bearish Divergence (Potential Short).
Visual Aid: Draws a line connecting the pivot points on the price chart to visualize the divergence clearly.
Optimized Filtering:
Zone Filter (Disabled by Default): Can be enabled to only show signals when RSI is Overbought (>65) or Oversold (<35).
Candle Filter: Bullish signals only appear on Green candles; Bearish signals only on Red candles.
3. Settings Guide
EMA Settings: Toggle the dashboard, adjust line width, or enable "Dynamic Transparency".
Fractal Settings: Show/Hide lines, change the default Purple color.
RSI Settings: Adjust RSI Length (Default 14) or Pivot Lookback.
Alerts: Set alerts for EMA crossovers or Divergence signals in the TradingView Alert menu.
4. How to Trade (Strategy Example)
Identify Trend: Check the EMA Dashboard. Is the status "Strong Bullish"? Are prices above the Orange EMA 21?
Check Structure: Look at the Purple Fractal lines. Is price making higher highs? Wait for a pullback to a previous Fractal Low (Support).
Confirm Entry: Look for a Green Bullish Divergence triangle or a bounce off the EMA 55/100.
🇨🇳 中文版:指标使用说明书
EMA Fractal Divergence (趋势结构融合指标)
集趋势、结构、动能于一体的综合交易系统
1. 指标概述
EMA Fractal Divergence 是一个旨在解决“图表杂乱”问题的全能型指标。它将交易中最重要的三个维度融合在一个脚本中,帮助交易者一眼看清市场全貌:
趋势 (Trend): 通过 EMA 均线组判断方向。
结构 (Structure): 通过分型 (Fractal) 识别关键支撑阻力位。
动能 (Momentum): 通过 RSI 背离捕捉反转信号。
2. 核心功能详解
A. EMA 均线组 (趋势判断)
均线配置: 包含 4 条指数移动平均线 (21, 55, 100, 200)。
EMA 21 (橙色): 短期趋势线,用于判断短期强弱。
EMA 55/100/200 (深灰色): 中长期趋势线,作为重要支撑/阻力带。
显示逻辑:
纯色显示: 默认状态,清晰明了。
动态透明度 (可选): 在设置中开启。开启后,当价格跌破均线时,均线会变淡(半透明),从而在下跌趋势中减少视觉干扰。
趋势面板 (右上角):
实时显示当前价格在各条均线的上方还是下方。
显示价格距离均线的乖离率 (%)。
综合状态: 自动判断当前是“强势”、“蓄势”、“震荡”还是“弱势”。
B. 前高前低分型 (市场结构)
分型连线 (紫色): 自动连接关键的波段高点和低点。
用于识别市场结构(如更高的高点 HH,更低的低点 LL)。
连线处通常是潜在的支撑或压力位。
价格面板 (右下角):
实时显示最近一个前高 (Previous High) 和 前低 (Previous Low) 的具体价格。
辅助判断突破进场点或止损点。
C. RSI 背离 (动能反转)
信号系统: 自动检测价格与 RSI 指标的背离情况。
绿色三角 (K线下): 看涨背离 (Bullish Div),潜在做多信号。
红色三角 (K线上): 看跌背离 (Bearish Div),潜在做空信号。
辅助连线: 出现信号时,会在主图画出对应的价格连线,方便复盘。
智能过滤:
区域过滤 (默认关闭): 旨在捕捉更多机会。如需更保守,可在设置中开启,仅检测超买(>65)/超卖(<35)区域的背离。
K线形态过滤: 看涨信号必须收阳线,看跌信号必须收阴线,提高胜率。
3. 设置指南
EMA设置: 可调整线条宽度、颜色,或开启/关闭“动态透明度”。
分型设置: 可自定义连线颜色(默认紫色)和粗细。
RSI背离: 可调整 RSI 长度(默认14)或 Pivot 回溯周期。
警报: 支持添加 TradingView 警报,包括“突破均线”或“发现背离”等条件。
4. 交易策略示例 (共振交易法)
顺势: 观察右上角面板,确认处于“强势”或均线向上发散(价格在橙色线之上)。
找位: 等待价格回调至紫色分型线(前低支撑)或 灰色 EMA 均线附近。
触发: 等待出现 绿色看涨背离三角,或价格收盘重新站上橙色 EMA 21,即可入场。
Mã được bảo vệ
Tập lệnh này được đăng dưới dạng mã nguồn đóng. Tuy nhiên, bạn có thể sử dụng tự do và không giới hạn – tìm hiểu thêm tại đây.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.
Mã được bảo vệ
Tập lệnh này được đăng dưới dạng mã nguồn đóng. Tuy nhiên, bạn có thể sử dụng tự do và không giới hạn – tìm hiểu thêm tại đây.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.