Function rgsl::statistics::variance_m[][src]

pub fn variance_m(data: &[f64], stride: usize, n: usize, mean: f64) -> f64

This function returns the sample variance of data relative to the given value of mean. The function is computed with \Hat\mu replaced by the value of mean that you supply,

\Hat\sigma^2 = (1/(N-1)) \sum (x_i - mean)^2