Corrected a bug in how mu, sigma are set