Improves stats

Merged improved stats work from evernote/pootle. Staging server: http://stats.testing.locamotion.org.