summaryrefslogtreecommitdiffstats
path: root/Lib/statistics.py
Commit message (Collapse)AuthorAgeFilesLines
* The stdev calculation is more accurate computing its own mean (#92220)Raymond Hettinger2022-05-031-2/+1
|
* Statistics internals: Make fewer calls to _coerce() when data types are ↵Raymond Hettinger2022-02-281-4/+9
| | | | mixed (GH-31619)
* bpo-46257: Convert statistics._ss() to a single pass algorithm (GH-30403)Raymond Hettinger2022-01-051-57/+43
|
* Fix double-space in exception message (GH-29955)Ned Batchelder2021-12-081-1/+1
|
* bpo-45876: Have stdev() also use decimal specific square root. (GH-29869)Raymond Hettinger2021-12-011-3/+2
|
* bpo-45876: Correctly rounded stdev() and pstdev() for the Decimal case ↵Raymond Hettinger2021-12-011-13/+66
| | | | (GH-29828)
* bpo-45876: Improve accuracy for stdev() and pstdev() in statistics (GH-29736)Raymond Hettinger2021-11-271-14/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Inlined code from variance functions * Added helper functions for the float square root of a fraction * Call helper functions * Add blurb * Fix over-specified test * Add a test for the _sqrt_frac() helper function * Increase the tested range * Add type hints to the internal function. * Fix test for correct rounding * Simplify ⌊√(n/m)⌋ calculation Co-authored-by: Mark Dickinson <dickinsm@gmail.com> * Add comment and beef-up tests * Test for zero denominator * Add algorithmic references * Add test for the _isqrt_frac_rto() helper function. * Compute the 109 instead of hard-wiring it * Stronger test for _isqrt_frac_rto() * Bigger range * Bigger range * Replace float() call with int/int division to be parallel with the other code path. * Factor out division. Update proof link. Remove internal type declaration Co-authored-by: Mark Dickinson <dickinsm@gmail.com>
* bpo-45766: Add direct proportion option to linear_regression(). (#29490)Raymond Hettinger2021-11-211-7/+24
| | | | | | | | | | | | | | | | | * bpo-45766: Add direct proportion option to linear_regression(). * Update 2021-11-09-09-18-06.bpo-45766.dvbcMf.rst * Use ellipsis to avoid round-off issues. * Update Misc/NEWS.d/next/Library/2021-11-09-09-18-06.bpo-45766.dvbcMf.rst Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no> * Update signature in main docs * Fix missing comma Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
* bpo-45851: Avoid full sort in statistics.multimode() (#29662)Raymond Hettinger2021-11-201-3/+5
| | | Suggested by Stefan Pochmann.
* Factor-out constant calculation. (GH-29491)Raymond Hettinger2021-11-091-2/+4
|
* bpo-20499: Rounding error in statistics.pvariance (GH-28230)Raymond Hettinger2021-09-091-42/+36
|
* bpo-39218: Improve accuracy of variance calculation (GH-27960)Raymond Hettinger2021-08-311-14/+19
|
* Update nonstandard variable names (GH-26540)Raymond Hettinger2021-06-041-5/+5
|
* bpo-44151: Various grammar, word order, and markup fixes (GH-26344)Raymond Hettinger2021-05-251-8/+8
|
* bpo-44151: linear_regression() minor API improvements (GH-26199)Zack Kneupper2021-05-251-15/+14
|
* bpo-44150: Support optional weights parameter for fmean() (GH-26175)Raymond Hettinger2021-05-211-7/+18
|
* Apply edits from Allen Downey's review of the linear_regression docs. (GH-26176)Raymond Hettinger2021-05-171-6/+6
|
* Improve speed and accuracy for correlation() (GH-26135)Raymond Hettinger2021-05-151-12/+14
|
* Eliminate duplicated calculations and unnecessary work for linear regression ↵Raymond Hettinger2021-05-061-2/+7
| | | | (GH-25922)
* Fix inconsistent fsum vs sum and fmean vs mean (GH-25898)Raymond Hettinger2021-05-041-3/+3
|
* bpo-38490: statistics: Add covariance, Pearson's correlation, and simple ↵Tymoteusz Wołodźko2021-04-251-1/+135
| | | | | linear regression (#16813) Co-authored-by: Tymoteusz Wołodźko <twolodzko+gitkraken@gmail.com
* bpo-43147: Remove archaic terminology. (GH-24462)Raymond Hettinger2021-02-081-4/+3
|
* bpo-38308: Add optional weighting to statistics.harmonic_mean() (GH-23914)Raymond Hettinger2020-12-241-18/+28
|
* Some reformatting (suggested by Black) and minor factoring. (GH-20865)Raymond Hettinger2020-06-141-31/+29
|
* bpo-40855: Fix ignored mu and xbar parameters (GH-20835)Raymond Hettinger2020-06-131-2/+4
|
* Minor code cleanups for statistics (GH-19873)Raymond Hettinger2020-05-031-76/+7
| | | | | * Minor cleanups: Removed unused code. Move C import near its Python version. * Clean-up whitespace
* bpo-40290: Add zscore() to statistics.NormalDist. (GH-19547)Raymond Hettinger2020-04-161-0/+11
|
* bpo-38385: Fix iterator/iterable terminology in statistics docs (GH-17111)Raymond Hettinger2019-11-121-1/+1
|
* bpo-38521: Fix error in NormalDist.__eq__() (GH-16840)Raymond Hettinger2019-10-181-1/+1
|
* Minor code and comment cleanup (GH-16315)Raymond Hettinger2019-09-211-1/+3
|
* bpo-36546: No longer a need to make "data" positional only (GH-16252)Raymond Hettinger2019-09-181-1/+1
|
* bpo-36018: Address more reviewer feedback (GH-15733)Raymond Hettinger2019-09-081-5/+27
|
* bpo-36324: Apply review comments from Allen Downey (GH-15693)Raymond Hettinger2019-09-051-21/+17
|
* bpo-37798: Add C fastpath for statistics.NormalDist.inv_cdf() (GH-15266)Dong-hee Na2019-08-231-73/+82
|
* bpo-36324: Update comments to include the target hash sums (GH-15110)Raymond Hettinger2019-08-041-0/+3
|
* Minor whitespace, indentation, and quoting changes to improve internal ↵Raymond Hettinger2019-07-211-53/+74
| | | | consistency and appease linters (GH-14888)
* bpo-36324: Make internal attributes for statistics.NormalDist() private. ↵Raymond Hettinger2019-07-211-34/+38
| | | | | | | | | | | | (GH-14871) * Make internals private * Finish making mu and sigma private * Add missing __hash__() method * Add blurb
* bpo-36546: Clean-up comments (GH-14857)Raymond Hettinger2019-07-191-9/+3
|
* bpo-36546: Mark first argument as position only (GH-14363)Raymond Hettinger2019-06-251-1/+1
|
* bpo-37158: Simplify and speed-up statistics.fmean() (GH-13832)Raymond Hettinger2019-06-051-4/+4
|
* bpo-36546: Add design notes to aid future discussions (GH-13769)Raymond Hettinger2019-06-031-0/+39
|
* bpo-36018: Make "seed" into a keyword only argument (GH-12921)Raymond Hettinger2019-04-231-1/+1
|
* bpo-35904: Add missing fmean() entry to the summary table (GH-12919)Raymond Hettinger2019-04-231-0/+1
|
* bpo-36546: Add statistics.quantiles() (#12710)Raymond Hettinger2019-04-231-4/+53
|
* bpo-27181: Add statistics.geometric_mean() (GH-12638)Raymond Hettinger2019-04-071-1/+21
|
* bpo-36326: Let inspect.getdoc() find docstrings for __slots__ (GH-12498)Raymond Hettinger2019-03-251-1/+2
|
* bpo-36324: Improved code formatting for the NormalDist.inv_cdf rational ↵Raymond Hettinger2019-03-191-46/+48
| | | | | approximation (GH-12448) https://bugs.python.org/issue36324
* NormalDist.inv_cdf(): In-line constants because the variable names were not ↵Raymond Hettinger2019-03-191-59/+46
| | | | informative (GH-12446)
* Add docstrings to the arithmetic methods in NormalDist() (GH-12426)Raymond Hettinger2019-03-191-14/+44
|
* bpo-36324: Add inv_cdf() to statistics.NormalDist() (GH-12377)Raymond Hettinger2019-03-191-0/+95
|