All indicators

Anchored VWAP

Jan 23, 2020

Static chart image
Support and ResistanceVolume BasedTime Based

The Anchored VWAP indicator provides a volume-weighted average price calculation that resets based on specific time-based anchors, allowing traders to identify value areas across various periodicities.

Usage

The Usage section focuses on how the indicator helps identify the average price paid for a security, weighted by volume, starting from a specific point in time. Traders typically use the Anchored VWAP to identify support and resistance levels or to determine the institutional "fair value" for a given period.

Examples of usage include:

  • Intraday Trading: Using the "Session" anchor to see the volume-weighted average price developing throughout the current trading day.
  • Swing Trading: Using "Week" or "Month" anchors to identify broader trends and significant price levels over longer durations.
  • Trend Confirmation: Observing price relative to the VWAP line; price staying above the VWAP suggests bullish sentiment, while price below suggests bearish sentiment.

Details

This implementation calculates the VWAP by accumulating the product of price (HLC3) and volume, then dividing by the total accumulated volume. Unlike a standard moving average, the calculation resets at the start of every new period defined by the user. The script logic accounts for overnight sessions and various calendar alignments to ensure the "Anchor Period" correctly triggers the reset across different timeframes.

Settings

Inputs

  • Anchor Period: Determines when the VWAP calculation resets. Options include:
    • Session: Resets at the start of each new trading session.
    • Week: Resets at the beginning of each week.
    • Month: Resets at the start of each new calendar month.
    • Year: Resets at the start of the calendar year.

FAQ

How do I use the Anchored VWAP?

Select the desired anchor period from the settings menu. The line will then plot the volume-weighted average price starting from the most recent reset point (e.g., the start of the month).

Does this work on all timeframes?

Yes, the script is designed to function across various timeframes, though the choice of anchor should be appropriate for the chart interval (e.g., using a "Year" anchor on a 1-minute chart may result in a very long-running calculation).

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.