summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStuart Archibald <stuart.archibald@googlemail.com>2016-06-15 11:59:26 +0100
committerStuart Archibald <stuart.archibald@googlemail.com>2016-06-15 11:59:26 +0100
commit3cb6927d0457e800364c26c6022d01e7fd8f2660 (patch)
treea7f247446d2e82d1c09727bf42ced827aefd5df7
parent330d023e5cfcc9aef7334e1b20f3068502054112 (diff)
downloadnumpy-3cb6927d0457e800364c26c6022d01e7fd8f2660.tar.gz
DOC: Clarify the effect of rcond in numpy.linalg.lstsq.
The `rcond` `kwarg` to `numpy.linalg.lstsq` influences the rank determination computation by specifying the level at which singular values should be *treated* as zero, it does not cause the singular values to be "set" to zero.
-rw-r--r--numpy/linalg/linalg.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/numpy/linalg/linalg.py b/numpy/linalg/linalg.py
index 1f3ba7c54..c0a84fc4f 100644
--- a/numpy/linalg/linalg.py
+++ b/numpy/linalg/linalg.py
@@ -1804,8 +1804,9 @@ def lstsq(a, b, rcond=-1):
of `b`.
rcond : float, optional
Cut-off ratio for small singular values of `a`.
- Singular values are set to zero if they are smaller than `rcond`
- times the largest singular value of `a`.
+ For the purposes of rank determination, singular values are treated
+ as zero if they are smaller than `rcond` times the largest singular
+ value of `a`.
Returns
-------