OBV, VWAP and anchored VWAP: volume, weights and source boundaries
Teaching tables and diagrams with explicit inputs, formulas, seeds, local conditions and limits when checking Elliott wave hypotheses.
Published: (UTC+3)
Русский · English · Deutsch · Español · Français · Italiano · 繁體中文 · 日本語 · 한국어
This lab connects indicators to a wave hypothesis through explicit calculations. Every example price, volume and parameter is invented. A positive indicator condition describes a local state; it does not establish an entire Elliott count or measure a probability of profit.
Invented inputs and calculation rules
The table contains completed bars. t is an ordinal index; O/H/L/C mean open/high/low/close and V is invented volume from one source, not an entire-market total. Dataset A has a preceding bar t=−1 with C=99, H=100, L=98. Windows include the current bar unless explicitly stated otherwise.
SMA_n is the mean of the latest n values. EMA_n uses α=2/(n+1) and RMA_n uses α=1/n; both recursions y_t=αx_t+(1−α)y_(t−1) start with the mean of the first n available values. Intermediate values are not rounded; tables display up to six decimals. “—” means insufficient history or an undefined value, not zero. Missing inputs are not replaced with zero. Short teaching periods are not recommended settings; the seeds and zero policies are declared here, without a claim of parity with every platform.
| Dataset | t | O | H | L | C | V |
|---|---|---|---|---|---|---|
| A | 0 | 99.5 | 101 | 99 | 100 | 10 |
| A | 1 | 101.5 | 103 | 101 | 102 | 12 |
| A | 2 | 100.5 | 102 | 100 | 101 | 8 |
| A | 3 | 103.5 | 105 | 103 | 104 | 15 |
| A | 4 | 102.5 | 104 | 102 | 103 | 9 |
| A | 5 | 105.5 | 107 | 105 | 106 | 20 |
| A | 6 | 103.5 | 105 | 103 | 104 | 11 |
| A | 7 | 106.5 | 108 | 106 | 107 | 18 |
| A | 8 | 104.5 | 106 | 104 | 105 | 14 |
| A | 9 | 107.5 | 109 | 107 | 108 | 22 |
| A | 10 | 103.5 | 105 | 103 | 104 | 16 |
Can an early undefined indicator value be replaced by zero and counted as a negative signal?
No. A missing full window and a calculated zero are different states; freeze the warm-up policy in advance.
OBV: close direction and whole-bar volume
OBV adds or subtracts the whole V based on the close change, not each trade’s direction. Formula and worked calculation: OBV_t=OBV_(t−1)+sgn(C_t−C_(t−1))V_t. OBV_(−1)=0; C_(−1)=99; OBV0=10. t7: 29+18=47.
An unchanged close adds 0; missing V is not zero. Shifting the OBV seed changes its level but not differences; compare the same volume source and type.
Local research predicate: t7: OBV_t>OBV_(t−1). OBV’s rise at t7 proves neither cash inflow nor aggressive buying of all 18 units. If V is tick volume, OBV weights update counts rather than executed volume. That series is not interchangeable with exchange volume without validation.
| t | C | V | ΔC | OBV |
|---|---|---|---|---|
| 0 | 100 | 10 | 1 | 10 |
| 1 | 102 | 12 | 2 | 22 |
| 2 | 101 | 8 | -1 | 14 |
| 3 | 104 | 15 | 3 | 29 |
| 4 | 103 | 9 | -1 | 20 |
| 5 | 106 | 20 | 3 | 40 |
| 6 | 104 | 11 | -2 | 29 |
| 7 | 107 | 18 | 3 | 47 |
| 8 | 105 | 14 | -2 | 33 |
| 9 | 108 | 22 | 3 | 55 |
| 10 | 104 | 16 | -4 | 39 |
Reproduce the highlighted calculation and evaluate the local predicate. Does the result establish the entire wave count?
47>29; ΔOBV=18. No. It is the result of the stated calculation on invented data, not proof of a wave structure or profit.
VWAP: price source and session start
This is a bar-based HLC3 VWAP proxy, not a sum over actual trades; the session begins at t0 and includes t0–10. Formula and worked calculation: TP=(H+L+C)/3; VWAPbar_t=Σ_(i=0..t)(TP_iV_i)/Σ_(i=0..t)V_i. t10: 16219/155=104.638710.
A new session resets both cumulative sums. ΣV=0 makes VWAP undefined; a single zero-volume bar is valid. Here TP=C because of input symmetry, not a general identity.
Local research predicate: t10: C>VWAPbar. At t10 C=104 is below VWAPbar. The level is neither a compulsory magnet nor every participant’s price. Tick weights would average update counts; a different venue or session timezone would produce another series.
| t | C | TP_HLC3 | V | ΣPV | ΣV | VWAPbar |
|---|---|---|---|---|---|---|
| 0 | 100 | 100 | 10 | 1000 | 10 | 100 |
| 1 | 102 | 102 | 12 | 2224 | 22 | 101.090909 |
| 2 | 101 | 101 | 8 | 3032 | 30 | 101.066667 |
| 3 | 104 | 104 | 15 | 4592 | 45 | 102.044444 |
| 4 | 103 | 103 | 9 | 5519 | 54 | 102.203704 |
| 5 | 106 | 106 | 20 | 7639 | 74 | 103.22973 |
| 6 | 104 | 104 | 11 | 8783 | 85 | 103.329412 |
| 7 | 107 | 107 | 18 | 10709 | 103 | 103.970874 |
| 8 | 105 | 105 | 14 | 12179 | 117 | 104.094017 |
| 9 | 108 | 108 | 22 | 14555 | 139 | 104.71223 |
| 10 | 104 | 104 | 16 | 16219 | 155 | 104.63871 |
Reproduce the highlighted calculation and evaluate the local predicate. Does the result establish the entire wave count?
104<16219/155=104.638710. No. It is the result of the stated calculation on invented data, not proof of a wave structure or profit.
Anchored VWAP: an anchor fixed in advance
Fix the anchor at t5 using the same HLC3 proxy and V as the session VWAP. Formula and worked calculation: AVWAP5_t=Σ_(i=5..t)(TP_iV_i)/Σ_(i=5..t)V_i, t≥5. t10: 10700/101=105.940594; VWAP0_10=16219/155=104.638710.
There is no value before t5; ΣV=0 is undefined. An anchor must be available when chosen: a pivot confirmed later cannot make the line retrospectively known earlier.
Local research predicate: t10: C>AVWAP5. The same bars give different levels for anchors 0 and 5. Choosing whichever line fits a price already seen is hindsight fitting. Neither anchor turns an average price into a wave-count invalidation rule.
| t | C | V | VWAP0 | AVWAP5 | ΣPV5 | ΣV5 |
|---|---|---|---|---|---|---|
| 0 | 100 | 10 | 100 | — | — | — |
| 1 | 102 | 12 | 101.090909 | — | — | — |
| 2 | 101 | 8 | 101.066667 | — | — | — |
| 3 | 104 | 15 | 102.044444 | — | — | — |
| 4 | 103 | 9 | 102.203704 | — | — | — |
| 5 | 106 | 20 | 103.22973 | 106 | 2120 | 20 |
| 6 | 104 | 11 | 103.329412 | 105.290323 | 3264 | 31 |
| 7 | 107 | 18 | 103.970874 | 105.918367 | 5190 | 49 |
| 8 | 105 | 14 | 104.094017 | 105.714286 | 6660 | 63 |
| 9 | 108 | 22 | 104.71223 | 106.305882 | 9036 | 85 |
| 10 | 104 | 16 | 104.63871 | 105.940594 | 10700 | 101 |
Reproduce the highlighted calculation and evaluate the local predicate. Does the result establish the entire wave count?
104<10700/101=105.940594; AVWAP5≠VWAP0. No. It is the result of the stated calculation on invented data, not proof of a wave structure or profit.
A testable condition and a wave strategy
For a study, freeze the source, timeframe, parameters, formula, availability time and alternative wave count first. Each section gives a local predicate with a threshold chosen for arithmetic practice. Record both positive and negative outcomes at bar close without selecting settings after seeing the result. Check a structural wave-rule violation from price separately.
RSI, averages, MACD and other price transforms share overlapping inputs. Several agreeing lines are not independent votes and do not supply probabilities that can be multiplied. A strategy test needs a separate sample and a predeclared outcome; simulated trades also need execution and cost assumptions. This lab supplies no trading performance, accuracy rate or product features.
| Value | Local research predicate |
|---|---|
| OBV: close direction and whole-bar volume | t7: OBV_t>OBV_(t−1) |
| VWAP: price source and session start | t10: C>VWAPbar |
| Anchored VWAP: an anchor fixed in advance | t10: C>AVWAP5 |
Three price transforms agree. Does that provide three independent confirmations and establish the count?
No. Shared inputs create dependence; local filters are checked separately from price rules, and usefulness needs another sample.