charton API / @chart-on/ta / vwap
Function: vwap()
vwap(
price,volume,newSession?,out?,state?):Float64Array
Defined in: volume.ts:22
Volume-weighted average price: sum(price * volume) / sum(volume) since the session start. Without newSession it runs over the whole series. price is usually (high + low + close) / 3. Lookback 0; NaN while the session has no volume. A NaN input gives NaN and starts a new session.
Pass state to keep the running sums for vwapAt.
Parameters
price
volume
newSession?
out?
Float64Array<ArrayBufferLike>
state?
Returns
Float64Array