OPEN-SOURCE SCRIPT

Adaptive Volatility Bands [AVB]

892
Adaptive Volatility Bands (AVB) is a volatility-aware trend-following overlay indicator built on the Kaufman Adaptive Moving Average (KAMA) and dynamically adjusted Bollinger-style bands.


syot kilat

**Mathematical Foundation:**


The core of AVB is the Kaufman Efficiency Ratio (ER), which measures the ratio of directional price movement to total price movement over a lookback period. An ER near 1.0 indicates a strong trend with minimal noise; an ER near 0.0 indicates choppy, range-bound conditions. The KAMA uses this ratio to automatically adjust its smoothing constant — responding quickly during trends and slowly during consolidation.

The bands around the KAMA are not static standard deviations. Instead, they use an adaptive standard deviation that widens when the Efficiency Ratio is low (noisy markets) and tightens when ER is high (trending markets). This creates bands that contract during consolidation (squeeze) and expand during breakouts.

syot kilat

**Signal Logic:**

Buy signals are generated when price touches the lower band with RSI in oversold territory during an uptrend, or when a squeeze releases with price above the KAMA. Sell signals fire at the upper band with RSI overbought during a downtrend, or at squeeze release below KAMA. Volume confirmation is applied to filter low-conviction signals.

syot kilat

**Features:**
- Kaufman Adaptive Moving Average with adjustable fast/slow smoothing periods
- Adaptive volatility bands that respond to market efficiency
- Volatility squeeze detection with bar coloring
- RSI and volume filters for signal confirmation
- ATR-based stop-loss and take-profit levels
- Real-time dashboard showing efficiency ratio, RSI, volatility regime, and trend direction
- Fully customizable colors and parameters

syot kilat

**Use Cases:**
Suitable for forex, crypto, commodities, and equities across all timeframes. Works well on 15-minute to daily charts.

Penafian

Maklumat dan penerbitan adalah tidak bertujuan, dan tidak membentuk, nasihat atau cadangan kewangan, pelaburan, dagangan atau jenis lain yang diberikan atau disahkan oleh TradingView. Baca lebih dalam Terma Penggunaan.