[SciPy-User] Is kKahan summation used in numpy.mean?

Yosef Meller yosefmel at post.tau.ac.il
Tue Apr 6 05:22:38 EDT 2010


I seem to be getting a much better accuracy from numpy.mean then from a loop 
of a += val; a /= num_vals. I've seen some discussion on mailing lists about 
using Kahan summation for mean(), so I suspect this is the reason, but I can't 
for the life of me find if it was finally implemented or not. Anybody knows?

Also, if you know where it is in the numpy source tree, please tell - I 
searched it the whole morning.

Thanks,
Yosef.



More information about the SciPy-User mailing list