All indicators

Volume Weighted Average Price (VWAP) with Extras

Feb 7, 2023

Static chart image
Dynamic OverlaysSupport and ResistanceVolume BasedSignalsTime BasedChannelsPivot Based (Retrospective)Volatility

The Volume Weighted Average Price with Extras indicator provides an advanced version of the standard VWAP by introducing unique anchor points such as price extremes and percentage-based price shifts to track volume-weighted trends more dynamically.

Usage

This tool is used to identify the average price a security has traded at throughout a specific period, weighted by volume. Beyond standard time-based anchors, users can utilize specific market events:

  • Percent Change: Automatically resets the VWAP calculation when the price moves beyond a user-defined percentage threshold.
  • Extreme High/Low: Resets the calculation when new lookback highs or lows are established, helping traders track trends starting from significant pivot points.
  • Event Anchoring: Anchors the VWAP to fundamental events like Earnings, Dividends, or Splits.

Details

The script calculates the Volume Weighted Average Price using the built-in ta.vwap function but adds logic to detect custom reset triggers. The "Percent Change" anchor is calculated by measuring the current candle's change relative to the previous candle; if this exceeds the "Threshold for price Percent Change" setting, a new VWAP period begins. The "Extreme" anchor monitors a specific lookback period to identify when the market breaks out of its recent range, signaling a potential shift in trend volume.

Settings

VWAP Settings

  • Anchor Period: Selects the trigger for resetting the VWAP (e.g., Percent Change, Extreme, Session, Earnings).
  • Source: The price data used for the calculation (default is HLC3).
  • Offset: Shifts the VWAP plots forward or backward on the chart.
  • Hide VWAP on 1D or Above: Disables the indicator on daily, weekly, or monthly timeframes.

Extra Settings

  • Lookback length for High and Low: The number of bars used to determine the "Extreme" price levels.
  • Threshold for price Percent Change: The percentage value required to trigger a new VWAP anchor when using the Percent Change mode.

Standard Deviation Bands Settings

  • Bands Multiplier (1-3): Sets the multiplier for the standard deviation bands.
  • Show Band Toggle: Enables or disables the visibility of the three available band levels.

FAQ

How do I use the Percent Change anchor?

Set the "Anchor Period" to "Percent Change" and adjust the "Threshold for price Percent Change" in the Extra Settings. The VWAP will restart whenever a price move exceeds your specified percentage.

Can I see multiple deviation bands at once?

Yes, you can enable up to three different standard deviation bands in the settings to create volatility channels around the VWAP line.

How can I access Volume Weighted Average Price with Extras?

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.