start of stats and test tools