Optimized stats tool.