PROTECTED SOURCE SCRIPT
Trend Warning / Direction (EMA20/50)

This indicator visualizes trend changes and consolidation phases using the 20 EMA and 50 EMA.
🔹 Trend Signals
• Green triangle (▲): EMA 20 crosses above EMA 50 → bullish trend signal
• Red triangle (▼): EMA 20 crosses below EMA 50 → bearish trend signal
• Crosses are confirmed on candle close to avoid false signals.
🔹 EMA Distance Warning
The indicator highlights low-momentum / squeeze zones when the distance between EMA 20 and EMA 50 falls below a configurable threshold.
• Yellow triangle with number:
Displays the current EMA distance in percent (without the % symbol).
• The warning threshold can be configured individually for each timeframe:
• 1m, 5m, 15m, 30m
• 1h, 4h, 8h
• 1D, 1W
• The active chart timeframe automatically determines which threshold is applied.
🔹 Customization
• Enable or disable EMA distance warnings via settings
• Adjust distance thresholds per timeframe
• Option to limit warning labels to one per bar
• Works on all markets and timeframes
🔹 Use Cases
• Trend identification
• Momentum exhaustion and consolidation detection
• Early warning before potential breakouts
• Trade confirmation in combination with other indicators
This indicator is non-repainting, lightweight, and designed for clean, actionable chart signals.
🔹 Trend Signals
• Green triangle (▲): EMA 20 crosses above EMA 50 → bullish trend signal
• Red triangle (▼): EMA 20 crosses below EMA 50 → bearish trend signal
• Crosses are confirmed on candle close to avoid false signals.
🔹 EMA Distance Warning
The indicator highlights low-momentum / squeeze zones when the distance between EMA 20 and EMA 50 falls below a configurable threshold.
• Yellow triangle with number:
Displays the current EMA distance in percent (without the % symbol).
• The warning threshold can be configured individually for each timeframe:
• 1m, 5m, 15m, 30m
• 1h, 4h, 8h
• 1D, 1W
• The active chart timeframe automatically determines which threshold is applied.
🔹 Customization
• Enable or disable EMA distance warnings via settings
• Adjust distance thresholds per timeframe
• Option to limit warning labels to one per bar
• Works on all markets and timeframes
🔹 Use Cases
• Trend identification
• Momentum exhaustion and consolidation detection
• Early warning before potential breakouts
• Trade confirmation in combination with other indicators
This indicator is non-repainting, lightweight, and designed for clean, actionable chart signals.
Script protégé
Ce script est publié en source fermée. Cependant, vous pouvez l'utiliser librement et sans aucune restriction – pour en savoir plus, cliquez ici.
Clause de non-responsabilité
Les informations et publications ne sont pas destinées à être, et ne constituent pas, des conseils ou recommandations financiers, d'investissement, de trading ou autres fournis ou approuvés par TradingView. Pour en savoir plus, consultez les Conditions d'utilisation.
Script protégé
Ce script est publié en source fermée. Cependant, vous pouvez l'utiliser librement et sans aucune restriction – pour en savoir plus, cliquez ici.
Clause de non-responsabilité
Les informations et publications ne sont pas destinées à être, et ne constituent pas, des conseils ou recommandations financiers, d'investissement, de trading ou autres fournis ou approuvés par TradingView. Pour en savoir plus, consultez les Conditions d'utilisation.