main: dispatch stats only if period > 0