[issue28327] statistics.geometric_mean gives incorrect results for mixed int/float inputs

Irit Katriel report at bugs.python.org
Fri Aug 20 05:51:12 EDT 2021


Irit Katriel <iritkatriel at gmail.com> added the comment:

I can't reproduce this now:

>>> statistics.geometric_mean([2, 3, 5, 7])
3.80675409583932
>>> statistics.geometric_mean([2, 3, 5, 7.0])
3.80675409583932
>>> statistics.geometric_mean([2, 3, 5.0, 7.0])
3.80675409583932
>>> statistics.geometric_mean([2, 3.0, 5.0, 7.0])
3.80675409583932
>>> statistics.geometric_mean([2.0, 3.0, 5.0, 7.0])
3.80675409583932
>>>


The current geometric_mean was added in PR12638. Is this issue about a previous version?

----------
nosy: +iritkatriel

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue28327>
_______________________________________


More information about the Python-bugs-list mailing list