Choose a published recursion and specify its denominator
Christian P. Fries describes E = ((N − v) × previous E + v × p) / N, with N a share-volume budget. His introductory paper motivates it as an approximation to the average price paid per share. It does not observe investors' actual holdings or cost bases. Linn Software also documents a budget calculated as a multiple of recent average volume. On this page that budget is the sum of the latest L volumes. Missing or negative volume in that window clears the recursive state; a recorded zero holds it.
- This page selects that average-volume form with multiplier L: S = L × SMA(volume, L) = sum of the latest L volumes, including the current bar. Then α = current volume / S and E = (1 − α) × previous E + α × current price.
- This is an explicit rolling-budget adaptation of the published recursion. The seed and missing-data rules below are choices for this implementation, not claims that every script named EVWMA uses them.
- N is a volume quantity, not the number of bars. A fixed N of 1,000 shares and a rolling sum over 20 bars are different specifications. Neither a rolling budget nor a fixed-budget proxy directly measures the cost basis of all shareholders.