bmel:variance-of¶
Category: Array & Statistics · Returns: bmel:number
Signature
bmel:variance-of(array: bmel:array<number>)
Description¶
Returns the population variance of all numeric values in an array. Computed as mean(x^2) - mean(x)^2. The square of bmel:stddev-of. Useful when combining multiple statistical measures (e.g. total variance of a composite metric).
Arguments¶
| Parameter | Type | Required | Description |
|---|---|---|---|
array | bmel:array<number> | The array of numeric values. |
Examples¶
Variance of the latencies of a run
bmel:variance-of({createChatCompletion:Response Payload[]}.$.latency_ms)
Variance of item prices
bmel:variance-of({getOrder:Response Payload}.$.items.price)