Refactoring - statistics under common interface, various improvements