avoid division by zero if stdv is 0

fixes #10