diff options
| author | Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> | 2021-05-16 19:47:57 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-05-16 19:47:57 -0700 |
| commit | e6755ba94b629a51819c9c076626afc187cded9b (patch) | |
| tree | a679bdfa687b0a395bda3db5df8d73771ff32f75 /Lib/statistics.py | |
| parent | d49877e6e745b9c3564bc86a81f4d05038f2b45b (diff) | |
| download | cpython-git-e6755ba94b629a51819c9c076626afc187cded9b.tar.gz | |
Apply edits from Allen Downey's review of the linear_regression docs. (GH-26176) (GH-26185)
Diffstat (limited to 'Lib/statistics.py')
| -rw-r--r-- | Lib/statistics.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/Lib/statistics.py b/Lib/statistics.py index db8c581068..c2f8dcd9ad 100644 --- a/Lib/statistics.py +++ b/Lib/statistics.py @@ -928,15 +928,15 @@ def linear_regression(regressor, dependent_variable, /): Return the intercept and slope of simple linear regression parameters estimated using ordinary least squares. Simple linear regression describes relationship between *regressor* and - *dependent variable* in terms of linear function:: + *dependent variable* in terms of linear function: dependent_variable = intercept + slope * regressor + noise - where ``intercept`` and ``slope`` are the regression parameters that are - estimated, and noise term is an unobserved random variable, for the - variability of the data that was not explained by the linear regression - (it is equal to the difference between prediction and the actual values - of dependent variable). + where *intercept* and *slope* are the regression parameters that are + estimated, and noise represents the variability of the data that was + not explained by the linear regression (it is equal to the + difference between predicted and actual values of dependent + variable). The parameters are returned as a named tuple. |
