Steven D'Aprano added the comment:

It seems to me that the basic Counter class should be left as-is, and if there 
are specialized methods used for statistics (such as normalize) it should go 
into a subclass in the statistics module.

The statistics module already uses Counter internally to calculate the mode.

It makes some sense to me for statistics to have a FrequencyTable (and 
CumulativeFrequencyTable?) class built on top of Counter. I don't think it 
makes sense to overload the collections.Counter type with these sorts of 
specialised methods.

----------
nosy: +steven.daprano

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue25478>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to