All indicators

Exponential Bollinger Bands [Updated Feb 2018]

Feb 11, 2018

Static chart image
ChannelsMoving AveragesVolatility

The Exponential Bollinger Bands indicator is a volatility-based technical analysis tool that utilizes an Exponential Moving Average (EMA) as its basis to identify potential overbought or oversold conditions. By applying standard deviation calculations to an exponential mean, this tool offers a more reactive alternative to traditional Bollinger Bands, allowing traders to visualize price extensions and volatility shifts with adjustable horizontal offsets.

Usage

The indicator can be used similarly to standard Bollinger Bands to identify trend strength and potential reversals. When price interacts with the Upper or Lower bands, it suggests the market is reaching a statistical extreme relative to its recent exponential average.

Traders often look for:

  • Volatitly Squeezes: When the bands contract, it indicates a period of low volatility often followed by a significant price breakout.
  • Mean Reversion: Prices returning to the center EMA line after touching or exceeding the outer bands.
  • Trend Following: During strong trends, price may "walk" along the outer bands.

The inclusion of an offset parameter allows users to shift the entire indicator forward or backward on the X-axis, which can be useful for aligning the bands with specific cyclical patterns or reducing lag perception.

Details

Unlike the standard Bollinger Band calculation which typically uses a Simple Moving Average (SMA), this script uses an Exponential Moving Average (EMA) as the "Basis". The volatility bands are calculated by determining the variance of the source price relative to this EMA.

The script calculates variance as the sum of squared differences between the source price and the EMA, divided by the sample size (len - 1), and then takes the square root to find the standard deviation. This deviation is then multiplied by a user-defined factor and added to/subtracted from the EMA to create the final upper and lower boundaries.

Settings

  • Source: The price data used for all calculations (e.g., Close, HL2, OHLC4).
  • Timeframe / # of period's: The lookback period used for the EMA and the standard deviation calculation.
  • Desired offset (# of bars): Determines the number of bars the indicator plots are shifted horizontally. Positive values shift to the right, negative values shift to the left.
  • # of STDEV's: The multiplier applied to the standard deviation to determine the width of the bands.

FAQ

How do I access the Exponential Bollinger Bands?

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

How does this differ from traditional Bollinger Bands?

Traditional Bollinger Bands use a Simple Moving Average (SMA) and standard deviation based on that SMA. This version uses an Exponential Moving Average (EMA), which puts more weight on recent price action, making the bands more responsive to recent volatility.

Can I use the offset for predictive analysis?

While the offset moves the visual representation of the bands, it does not change the underlying calculation data. It is primarily used for visual alignment and historical back-testing of shifted cycles.

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.