From: Forrest Voight Date: Mon, 6 Feb 2012 22:57:33 +0000 (-0500) Subject: fixed bug in rounding fix X-Git-Tag: 0.8.4~16 X-Git-Url: https://git.novaco.in/?a=commitdiff_plain;h=c9b75c94c49e742e378a834c2c33c81cb29b715a;p=p2pool.git fixed bug in rounding fix --- diff --git a/p2pool/util/math.py b/p2pool/util/math.py index 50a279d..614a0f2 100644 --- a/p2pool/util/math.py +++ b/p2pool/util/math.py @@ -152,7 +152,7 @@ def format_binomial_conf(x, n, conf=0.95, f=lambda x: x): if n == 0: return '???' left, right = minmax(map(f, binomial_conf_interval(x, n, conf))) - return '~%.1f%% (%.f-%.f%%)' % (100*f(x/n), left-1/2, right+1/2) + return '~%.1f%% (%.f-%.f%%)' % (100*f(x/n), 100*left-1/2, 100*right+1/2) def reversed(x): try: