Skip to content

arithmeticMean

Subhajit Sahu edited this page Aug 8, 2022 · 1 revision

Find the average of numbers.

Similar: arithmeticMean, geometricMean, harmonicMean, quadriaticMean, cubicMean.
Similar: arithmeticMean, median, modes, variance, range.


function arithmeticMean(...xs)
// xs: a list of numbers

const xmath = require('extra-math');


xmath.arithmeticMean(1, 2);
// → 1.5

xmath.arithmeticMean(1, 2, 3);
// → 2

xmath.arithmeticMean(1, 2, 3, 4);
// → 2.5


References

Clone this wiki locally