From: Forrest Voight Date: Sat, 4 Feb 2012 06:45:31 +0000 (-0500) Subject: fixed format_binomial_conf not scaling percentages to 100 X-Git-Tag: 0.8.3^0 X-Git-Url: https://git.novaco.in/?a=commitdiff_plain;h=3cfeee920a30821856979d87719116c1ca03f168;p=p2pool.git fixed format_binomial_conf not scaling percentages to 100 --- diff --git a/p2pool/util/math.py b/p2pool/util/math.py index a332478..e08cb1f 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%% (%i-%i%%)' % (f(x/n), int(100*left), 100-int(100-100*right)) + return '~%.1f%% (%i-%i%%)' % (100*f(x/n), int(100*left), 100-int(100-100*right)) def reversed(x): try: