OPEN-SOURCE SCRIPT
Commodity Channel Index Trend | Dextra

Overview
A smart, noise-filtered CCI that transforms chaotic oscillations into clear trend states. Instead of flipping constantly, CCI Trend locks into bullish or bearish mode only when momentum truly breaks out — using hysteresis to eliminate false signals.
Instant visual feedback via fully colored candles:
- Emerald Green = Bullish trend locked
- Hot Pink = Bearish trend locked
How It Works
1. Calculates standard CCI using EMA and price deviation
2. Triggers trend only when CCI exits the neutral zone
3. Locks the state until CCI breaks the opposite threshold
4. Updates CCI line color and candle appearance in real time
A smart, noise-filtered CCI that transforms chaotic oscillations into clear trend states. Instead of flipping constantly, CCI Trend locks into bullish or bearish mode only when momentum truly breaks out — using hysteresis to eliminate false signals.
Instant visual feedback via fully colored candles:
- Emerald Green = Bullish trend locked
- Hot Pink = Bearish trend locked
How It Works
1. Calculates standard CCI using EMA and price deviation
2. Triggers trend only when CCI exits the neutral zone
3. Locks the state until CCI breaks the opposite threshold
4. Updates CCI line color and candle appearance in real time
Script open-source
Dans l'esprit TradingView, le créateur de ce script l'a rendu open source afin que les traders puissent examiner et vérifier ses fonctionnalités. Bravo à l'auteur! Bien que vous puissiez l'utiliser gratuitement, n'oubliez pas que la republication du code est soumise à nos Règles.
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 open-source
Dans l'esprit TradingView, le créateur de ce script l'a rendu open source afin que les traders puissent examiner et vérifier ses fonctionnalités. Bravo à l'auteur! Bien que vous puissiez l'utiliser gratuitement, n'oubliez pas que la republication du code est soumise à nos Règles.
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.