Advanced Donchian Channels

This indicator enhances the classic Donchian Channel with powerful contextual features to support modern breakout and volatility-based trading strategies.
🔹 Core Features:
Donchian Bands: Plots the highest high and lowest low over a configurable lookback period.
Dynamic Fill Shading:
- Color-coded based on the slope of the midline (Basis): Default settings are Green for uptrend, Red for downtrend, Silver for flat, Gray for narrow volatility.
- All fill colors are fully customizable.
Volatility Filter:
- Detects when the channel width is narrow using either a fixed value or a percentage of price.
- Optionally shades only during low-volatility (compression) periods.
Customizable Style:
- Adjustable opacity, offsets, and color settings to suit your charting style.
🛠 Use Cases:
- Spot potential breakout setups after periods of low volatility.
- Identify trend direction via basis slope shading.
- Combine with momentum or volume tools for high-probability entries.
Skrip sumber terbuka
Dalam semangat sebenar TradingView, pencipta skrip ini telah menjadikannya sumber terbuka supaya pedagang dapat menilai dan mengesahkan kefungsiannya. Terima kasih kepada penulis! Walaupun anda boleh menggunakannya secara percuma, ingat bahawa menerbitkan semula kod ini adalah tertakluk kepada Peraturan Dalaman kami.
Untuk akses pantas pada carta, tambah skrip ini kepada kegemaran anda — ketahui lebih lanjut di sini.
Penafian
Skrip sumber terbuka
Dalam semangat sebenar TradingView, pencipta skrip ini telah menjadikannya sumber terbuka supaya pedagang dapat menilai dan mengesahkan kefungsiannya. Terima kasih kepada penulis! Walaupun anda boleh menggunakannya secara percuma, ingat bahawa menerbitkan semula kod ini adalah tertakluk kepada Peraturan Dalaman kami.
Untuk akses pantas pada carta, tambah skrip ini kepada kegemaran anda — ketahui lebih lanjut di sini.