Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions Lib/statistics.py
Original file line number Diff line number Diff line change
Expand Up @@ -810,8 +810,7 @@ def deco(builder):
@register('normal', 'gauss')
def normal_kernel():
sqrt2pi = sqrt(2 * pi)
sqrt2 = sqrt(2)
neg_sqrt2 = -sqrt2
neg_sqrt2 = -sqrt(2)
pdf = lambda t: exp(-1/2 * t * t) / sqrt2pi
cdf = lambda t: 1/2 * erfc(t / neg_sqrt2)
invcdf = lambda t: _normal_dist_inv_cdf(t, 0.0, 1.0)
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Improved the accuracy of ``statistics.NormalDist.cdf`` for negative inputs.
Improved ``statistics.NormalDist.cdf`` accuracy for inputs smaller than the mean.
Loading