All indicators

Bollinger Bands

Jan 17, 2022

Static chart image
SignalsChannelsMoving AveragesVolatility

The Bollinger Bands indicator is a modified volatility-based tool designed to identify potential trend reversals by combining standard deviation bands with an adaptive SMA signal filter.

Usage

The script is primarily used to identify reversal opportunities rather than trend continuations. A bullish condition is met when the price is above the lower band while the price remains above the adaptive SMA filter. Conversely, a bearish outlook is suggested when the price crosses under the lower band or falls below the filter.

For the most effective signals, look for:

  • Bullish Reversals: Seek long signals after a sustained downtrend where the price has interacted with the lower bands multiple times.
  • Bearish Reversals: Seek short signals after an extended uptrend where the price has breached the upper bands at least 3-4 times.

The indicator is equipped with an adaptive filter that changes its lookback period based on the chart timeframe (e.g., higher lengths for lower timeframes and shorter lengths for higher timeframes) to reduce noise.

Details

This implementation differs from standard Bollinger Bands by utilizing separate basis calculations for the upper and lower bounds. The upper band is derived from a smoothed highest high, while the lower band is derived from a smoothed lowest low. A standard deviation multiplier is then applied to these distinct bases.

The included adaptive SMA filter helps filter out "noisy" signals. The script automatically adjusts the filter length based on the current timeframe, ranging from 200 on 1-minute charts to 13 on weekly charts, ensuring the trend detection remains relevant to the specific period being traded.

Settings

  • BB Length: Determines the lookback period for the standard deviation calculation.
  • Source: The price data point used for calculations (defaulted to 'low').
  • StdDev: The multiplier for the standard deviation. Lower values are generally recommended for lower timeframes.
  • Offset: Shifts the plots forward or backward in time on the chart.

FAQ

How do I use the adaptive filter?

The filter is automatic; it detects your chart's timeframe and adjusts the SMA length accordingly to provide the most relevant trend filtering for that specific period.

When is the best time to enter a trade?

The script is optimized for trend reversals. The ideal scenario is entering a trade after a prolonged trend where the price has repeatedly tested or broken the outer bands, signaling exhaustion.

How can I access this tool?

You can get access on the LuxAlgo Library for charting platforms like TradingView, MetaTrader (MT4/MT5), and NinjaTrader for free.

Free indicator

Get free access to this indicator on the platforms below.

TradingView
NinjaTrader
MetaTrader 4/5

Unlock the entire LuxAlgo Library

Every indicator, every strategy, full charts, and complete access to Quant — our AI agent.