Refactor Stats collection.