Compute mean and standard deviation of a sample set.