indicator · on price · open source

Volume-Weighted Moving Average

Deepwick · @deepwickv1Updated 2 Oct 2026▲ 0 users
Running…
Loading chart…

About

Volume-Weighted Moving Average weighs each bar's price by its volume over the lookback. Bars with heavier flow pull the line harder, so the VWMA reflects where real money traded — not just where price ticked.

  • Most useful on markets with meaningful volume variation (equities, futures, large-cap crypto).
  • Pair with a price MA to see when price and flow diverge.
  • Raise N to anchor it to longer-term participation.

Source code

//@version=5
indicator("Volume-Weighted Moving Average", overlay=true)
len = input.int(20, "Length", minval=1, maxval=500)
src = input.source("close", "Source")
vwma = ta.vwma(src, len)
p_VWMA = plot(vwma, "VWMA", color=color.teal, linewidth=2)
alertcondition(ta.crossover(close, vwma), "Price crosses above VWMA", "Price crossed above the VWMA")
alertcondition(ta.crossunder(close, vwma), "Price crosses below VWMA", "Price crossed below the VWMA")

Comments

No comments yet.

Sign in to comment.