This indicator combines the power of the Commodity Channel Index (CCI) with adaptive trend filters and divergence detection to identify high-probability trading opportunities. It's designed to reduce false signals by incorporating trend direction and divergence confirmation.
🔍 How It Works:
1. Trend Detection: - Uses an adaptive Simple Moving Average (SMA) that automatically adjusts between daily and weekly timeframes - Daily mode: Default 200 SMA for longer-term trend - Weekly mode: Default 40 SMA for broader market perspective - Trend direction is determined by comparing current SMA value to its previous value
2. CCI Component: - Traditional CCI calculation with customizable length (default: 20) - Adjustable overbought (default: +100) and oversold (default: -100) levels - Color-coded CCI line for quick visual reference: * Green: Overbought and rising * Red: Oversold and falling * Gray: Neutral zone
3. Signal Generation: - Buy Signal (Green Background): * CCI crosses above oversold level AND * Main trend is confirmed bullish (rising SMA) - Sell Signal (Red Background): * CCI crosses below overbought level AND * Main trend is confirmed bearish (falling SMA)
4. Divergence Detection: - Automatically identifies bullish and bearish divergences - Bullish Divergence: Price makes lower low while CCI makes higher low - Bearish Divergence: Price makes higher high while CCI makes lower high - Visualized with distinct markers on the CCI line - Can be used to set up alerts for divergence confirmations
⚙️ Customization Options: - CCI calculation length and price source - Overbought/Oversold levels - SMA lengths for daily and weekly modes - Divergence lookback period - Signal colors and visualization settings
🔔 Alert Capabilities: - Set alerts for CCI crossovers of overbought/oversold levels - Create divergence detection alerts - Configure trend change notifications - Combine multiple conditions for complex alert strategies
💡 Trading Tips: - Combine divergence signals with trend direction for better accuracy - Wait for signal confirmation before entering trades - Use additional indicators or price action for exit decisions
This indicator helps traders identify potential trend reversals while keeping them aligned with the main market trend. Perfect for both trend following and counter-trend strategies when used appropriately.
Siguiendo fielmente el espíritu de TradingView, el autor de este script lo ha publicado en código abierto, permitiendo que otros traders puedan entenderlo y verificarlo. ¡Olé por el autor! Puede utilizarlo de forma gratuita, pero tenga en cuenta que la reutilización de este código en la publicación se rige por las Normas internas. Puede añadir este script a sus favoritos y usarlo en un gráfico.
La información y las publicaciones que ofrecemos, no implican ni constituyen un asesoramiento financiero, ni de inversión, trading o cualquier otro tipo de consejo o recomendación emitida o respaldada por TradingView. Puede obtener información adicional en las Condiciones de uso.