From e6d1cc2c01a1ce10af7383c3d2abbc7610fb6220 Mon Sep 17 00:00:00 2001 From: Warren Weckesser Date: Sat, 30 Nov 2019 21:59:19 -0500 Subject: DOC: lib: Use a clearer example of ddof in the notes of the cov docstring. Use `ddof = 1` instead of 9, and remove a confusing comment. Closes gh-15010. --- numpy/lib/function_base.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'numpy/lib/function_base.py') diff --git a/numpy/lib/function_base.py b/numpy/lib/function_base.py index 3ad630a7d..499120630 100644 --- a/numpy/lib/function_base.py +++ b/numpy/lib/function_base.py @@ -2305,7 +2305,7 @@ def cov(m, y=None, rowvar=True, bias=False, ddof=None, fweights=None, >>> m = np.arange(10, dtype=np.float64) >>> f = np.arange(10) * 2 >>> a = np.arange(10) ** 2. - >>> ddof = 9 # N - 1 + >>> ddof = 1 >>> w = f * a >>> v1 = np.sum(w) >>> v2 = np.sum(w * a) -- cgit v1.2.1