On this page
statistics.pvariance
Prev: statistics.pstdev | Up: statistics | Next: statistics.quantiles
Rel: statistics.correlation, statistics.covariance, statistics.fmean, statistics.geometric_mean
Ref: docs.python.org — statistics.pvariance
Tags: #public #python3 #stdlib #statistics
Import
import statistics
from statistics import pvariance
Signature & Overview
statistics.pvariance(data, mu=None)
Return the population variance of data.
Usage
import statistics
assert statistics.pvariance([2, 4, 4, 4, 5, 5, 7, 9]) == 4.0
Gotchas
- Population variance ($N$ denominator): Pass
mu=if the population mean is already known.
REPL Inspect
from statistics import pvariance
help(pvariance)
Linked from
Related notes
- tuts/python3/stdlib_module/statistics/pstdev Linked here; links to this page; shared tags: #statistics, #stdlib
- tuts/python3/stdlib_module/statistics/quantiles Linked here; links to this page; shared tags: #statistics, #stdlib
- tuts/python3/stdlib_module/statistics Linked here; links to this page; shared tags: #stdlib
- tuts/python3/stdlib_module/statistics/correlation Linked here; shared tags: #statistics, #stdlib
- tuts/python3/stdlib_module/statistics/covariance Linked here; shared tags: #statistics, #stdlib
- tuts/python3/stdlib_module/statistics/fmean Linked here; shared tags: #statistics, #stdlib
- tuts/python3/stdlib_module/statistics/geometric_mean Linked here; shared tags: #statistics, #stdlib
- tuts/python3/stdlib_module/statistics/harmonic_mean shared tags: #statistics, #stdlib
- tuts/python3/stdlib_module/statistics/kde shared tags: #statistics, #stdlib
- tuts/python3/stdlib_module/statistics/kde_random shared tags: #statistics, #stdlib