statistics.variance() - statistics
Return the sample variance of data, an iterable of at least two real-valued
numbers. Variance, or second moment about the mean, is a measure of the
variability (spread or dispersion) of data. A large variance indicates that
the data is spread out; a small variance indicates it is clustered closely
around the mean.
Syntax
statistics.variance(data, xbar=None)
Example
>>> data = [2.75, 1.75, 1.25, 0.25, 0.5, 1.25, 3.5]
>>> variance(data)
1.3720238095238095
Output / Return Value
Limitations
Alternatives / See Also
Reference