StatsActivity refactoring
Correcting bug in average computing, refactoring
Merge branch 'master' into HEAD