Volume reference
All 6 volume in AlgoBarsX, each with its parameters, defaults, ranges and an example: vwap, obv, cmf, ad_line, pvt, volume_osc.
vwap obv cmf ad_line pvt volume_osc
vwap(anchor = "session", on = bars())→ series<price>#
Volume-weighted average price, restarting at each session or period.
Parameters
| Name | Type | Default | What it is |
|---|---|---|---|
anchor | string | "session" | Where the average restarts. |
on | BarSet | bars() | Bars to calculate on; defaults to the script's own bars. |
fair = vwap(anchor: "session")strategyindicatoralertlibrarysince 1.0
obv(on = bars())→ series<number>#
On-balance volume.
Parameters
| Name | Type | Default | What it is |
|---|---|---|---|
on | BarSet | bars() | Bars to calculate on; defaults to the script's own bars. |
balance_volume = obv()strategyindicatoralertlibrarysince 1.0
cmf(length = 20, on = bars())→ series<number>#
Chaikin money flow.
Parameters
| Name | Type | Default | Range | What it is |
|---|---|---|---|---|
length | int | 20 | 1 to 5000 | Number of bars in the calculation. |
on | BarSet | bars() | Bars to calculate on; defaults to the script's own bars. |
money_flow = cmf(20)strategyindicatoralertlibrarysince 1.0
ad_line(on = bars())→ series<number>#
Accumulation/distribution line.
Parameters
| Name | Type | Default | What it is |
|---|---|---|---|
on | BarSet | bars() | Bars to calculate on; defaults to the script's own bars. |
ad = ad_line()strategyindicatoralertlibrarysince 1.0
pvt(on = bars())→ series<number>#
Price volume trend.
Parameters
| Name | Type | Default | What it is |
|---|---|---|---|
on | BarSet | bars() | Bars to calculate on; defaults to the script's own bars. |
trend_volume = pvt()strategyindicatoralertlibrarysince 1.0
volume_osc(fast = 5, slow = 10, on = bars())→ series<number>#
Volume oscillator.
Parameters
| Name | Type | Default | Range | What it is |
|---|---|---|---|---|
fast | int | 5 | 1 to 5000 | Fast length. |
slow | int | 10 | 1 to 5000 | Slow length. |
on | BarSet | bars() | Bars to calculate on; defaults to the script's own bars. |
vo = volume_osc(5, 10)strategyindicatoralertlibrarysince 1.0