Computes the population or sample variance (depending on passed arguments).
where is the size of (or number of observations in) vector x,
are individual elements in x,
(ddof) is a degrees of freedom adjustment
(ddof = 0.0 for population variance, ddof = 1.0 for sample variance), and
is the arithmetic mean of x.
Impure wrapper function for f_sts_var_core.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real(kind=wp), | intent(in) | :: | x(:) |
x vector (assumed size array) |
||
| real(kind=wp), | intent(in), | optional | :: | ddf |
delta degrees of freedom |
variance