fixed a bug with recreation of chisq, etc.