Import std.math.stats
Mean
function
@PanicsAtCaller Public Function Mean<T: Bounded>(values: T[]): Double
The mean, the sum over the count, or the sum of each value's share where the sum overflows and
the values don't. No values panics.
Examples
Local scores = [2, 4, 4, 4, 5, 5, 7, 9]
Expect(Mean(scores) == 5.0)
Expect(Median(scores) == 4.5)
Expect(PopulationStdDev(scores) == 2.0)
Expect(Percentile(scores, 100) == 9.0)Report an issue with this page or with FutureBlitz on GitHub.