small refactoring - extract common part of statistics classes into base class