period stats bug --div by zero

in javascript graph