mean static method

double mean(
  1. Iterable<num> ns
)

Mean value of ns entries.

Implementation

static double mean(Iterable<num> ns) {
  if (ns.isEmpty) return 0;
  return sum(ns) / ns.length;
}