Specify statistics using names, not classes
Fix some tests