Arithmetic mean, optionally trimmed. Equivalent to R's mean(). Accurate to the last bit: the sum is taken in double-double and corrected by the mean deviation, as R corrects its long double mean.
mean()
mean([1, 2, 3, 10]); // 4mean([1, 2, 3, 10], { trim: 0.25 }); // 2.5 Copy
mean([1, 2, 3, 10]); // 4mean([1, 2, 3, 10], { trim: 0.25 }); // 2.5
Arithmetic mean, optionally trimmed. Equivalent to R's
mean(). Accurate to the last bit: the sum is taken in double-double and corrected by the mean deviation, as R corrects its long double mean.