varianceif() (aggregation function)
Calculates the variance of Expr across the group for which Predicate evaluates to
- Can be used only in context of aggregation inside summarize
- Expr: Expression that will be used for aggregation calculation.
- Predicate: predicate that if true, the Expr calculated value will be added to the variance.
The variance value of Expr across the group where Predicate evaluates to
range x from 1 to 100 step 1 | summarize varianceif(x, x%2 == 0)