chi-squared update