At http://bazaar.launchpad.net/%7Ebzr/bzr-repodetails/trunk

------------------------------------------------------------
revno: 17
revision-id: [email protected]
parent: [email protected]
committer: John Arbash Meinel <[email protected]>
branch nick: trunk
timestamp: Wed 2008-12-24 11:52:57 -0600
message:
  If we do floating point for average, we need floating point for exp_x2
=== modified file 'gather_stats.py'
--- a/gather_stats.py   2008-12-24 17:49:09 +0000
+++ b/gather_stats.py   2008-12-24 17:52:57 +0000
@@ -128,7 +128,7 @@
         # See http://en.wikipedia.org/wiki/Standard_deviation
         # Arguably, we should be using "count-1" rather than count, depending
         # on whether you consider this a full population, or just a sample
-        exp_x2 = sum_of_squared / count
+        exp_x2 = float(sum_of_squared) / count
         stddev = math.sqrt(exp_x2 - avg*avg)
         return avg, stddev
 

-- 
bazaar-commits mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/bazaar-commits

Reply via email to