## Going to the chi-square table, welook in the row for 1 d.f.

Comparing the value of 27.77 to the chi-square distribution for1 degree of freedom, we estimate that the probability of gettingthis value or higher of the statistic is less than 1%.

Photo provided by Flickr

Sometimes, a population is created by bringing together males and females with different allele frequencies. In this case, the assumption of a single population is violated until after the first generation, so the first generation will not have Hardy–Weinberg equilibrium. Successive generations will have Hardy–Weinberg equilibrium.

## So the chi-square test doesn't give usexactly the right answer.

Photo provided by Flickr

The G–test of goodness-of-fit is an alternative to the ; each of these tests has some advantages and some disadvantages, and the results of the two tests are usually very similar. You should read the section on near the bottom of this page, pick either chi-square or G–test, then stick with that choice for the rest of your life. Much of the information and examples on this page are the same as on the chi-square test page, so once you've decided which test is better for you, you only need to read one.

## You use the chi-square test of goodness-of ..

An intrinsic null hypothesis is one where you estimate one or more parameters from the data in order to get the numbers for your null hypothesis. As described above, one example is Hardy-Weinberg proportions. For an intrinsic null hypothesis, the number of degrees of freedom is calculated by taking the number of values of the variable, subtracting 1 for each parameter estimated from the data, then subtracting 1 more. Thus for Hardy-Weinberg proportions with two alleles and three genotypes, there are three values of the variable (the three genotypes); you subtract one for the parameter estimated from the data (the allele frequency, p); and then you subtract one more, yielding one degree of freedom. There are other statistical issues involved in testing fit to Hardy-Weinberg expectations, so if you need to do this, see Engels (2009) and the older references he cites.

## Pearson's chi-squared test - Wikipedia

McDonald (1989) examined variation at the Mpi locus in the amphipod crustacean Platorchestia platensis collected from a single location on Long Island, New York. There were two alleles, Mpi90 and Mpi100 and the genotype frequencies in samples from multiple dates pooled together were 1203 Mpi90/90, 2919 Mpi90/100, and 1678 Mpi100/100. The estimate of the Mpi90 allele proportion from the data is 5325/11600=0.459. Using the Hardy-Weinberg formula and this estimated allele proportion, the expected genotype proportions are 0.211 Mpi90/90, 0.497 Mpi90/100, and 0.293 Mpi100/100. There are three categories (the three genotypes) and one parameterestimated from the data (the Mpi90allele proportion), so there is one degree of freedom. The result is chi-square=1.08, 1 d.f., P=0.299, which is not significant. You cannot reject the null hypothesis that the data fit the expected Hardy-Weinberg proportions.

## Chi-squared Test — bozemanscience

There is 1 (degrees of freedom for test for Hardy–Weinberg proportions are # genotypes − # alleles). The 5% for 1 degree of freedom is 3.84, and since the χ2 value is less than this, the that the population is in Hardy–Weinberg frequencies is not rejected.