AVGPRICE computes the arithmetic mean of a bar's four canonical prices: Open, High, Low, and Close. The formula $\frac{O + H + L + C}{4}$ produces a single representative price that weights all four price components equally, unlike Typical Price (which excludes Open) or Weighted Close (which double-weights Close). This equal weighting makes AVGPRICE the least biased single-bar summary statistic, useful as a neutral input to downstream indicators when no particular price component deserves emphasis. The calculation is stateless, requires no warmup, and costs a single FMA instruction per bar.
## Historical Context
Average Price is one of the oldest price transforms in technical analysis, predating computer-based charting by decades. Its inclusion in the TA-Lib function set (`TA_AVGPRICE`) standardized it as a canonical operation alongside MEDPRICE, TYPPRICE, and WCLPRICE. The four-price average gained popularity because it distributes weight across the full intra-bar range: Open captures the session's starting sentiment, High and Low bound the extremes where supply and demand exhausted themselves, and Close reflects the final consensus.
In practice, AVGPRICE and OHLC4 are identical. QuanTAlib exposes both: `TBar.OHLC4` as a zero-cost computed property for inline use, and `Avgprice` as a streaming indicator class supporting bar correction, event chaining, and batch processing. The indicator form exists because downstream consumers (Quantower adapters, chained indicator pipelines) require the `ITValuePublisher` interface and `isNew` rollback semantics that a bare struct property cannot provide.