homeaccount_circle
Chi-squared testComments

Chi-squared test

The Chi-squared test (or goodness of fit) is a test to determine if the observed results deviate too far from a theoretical expectation.

Fit means how closely the observed results agree with the expected results. To measure the goodness of fit, we use the Chi-square test. In research, it is often necessary to compare experimentally observed numbers of items in several categories with numbers that are predicted on the basis of some hypothesis. Genetic analysis often requires the interpretation of numbers in various phenotypic classes.

  1. Look up the Χ2 table to find the closest p-value for the Χ2 number you obtained and the corresponding degree of freedom.
  2. The p-value is the probability that a worse fit would be obtained by chance, assuming that the hypothesis is true.
  3. If the hypothesis is true, then the observed numbers should be reasonably close to the expected numbers, and the Χ2 value is small.
  4. If the hypothesis is not true when the observed numbers deviate too much from and expected numbers and the Χ2 value is large.
  5. The p-value is commonly set at 0.05 as a cut-off point. Accept the hypothesis if your Χ2 value is smaller than the Χ2 value for p=0.05 in the table, and reject the hypothesis if your Χ2 value is larger than the Χ2 value for p=0.05 in the table.

Chi-squared table

°'s of FreedomProbability
.9.5.1.05.01
10.020.462.713.846.64
20.211.394.615.999.21
30.582.376.257.8211.35
41.063.367.789.4913.28
51.614.359.2411.0715.09

Example Chi-squared (Χ2) tests

We hypothesize that a certain fruit fly that we believe is a dihybrid heterozygote of genotype AaBb (A are B independently segregate). To test this hypothesis, we cross this fly to a fly that we know is AaBb and expect a 9:3:3:1 ratio of A-B-, A-bb, aaB-, and aabb in the progeny.

Here are expected results of a AbBb x AaBb cross:

9A_B_(red eyes; straight wings)
3A_bb(red eyes; curly wings)
3aaB_(white eyes; straight wings)
1aabb(white eyes; curly wings)

However, even if the hypothesis is true, in real life we often do not get a exact 9:3:3:1 ratio. We might instead get the following observed data:

Here are observed results of a AbBb x AaBb cross:

921A_B_(red eyes; straight wings)
310A_bb(red eyes; curly wings)
274aaB_(white eyes; straight wings)
95aabb(white eyes; curly wings)
Total = 1600

What the Χ2 test tells you is whether these observed results are close enough to the expected results (9:3:3:1), and from that, we can either accept or reject our hypothesis that this fly we obtained is indeed a dihybrid heterozygote.

To calculate the Χ2 value, it is most clear if you make a table.

A-B-A-bbAaB-aabb
observed92131027495
expected900 = (9/16 of 1600)300 = (3/16 of 1600)300 = (3/16 of 1600)100 = (1/16 of 1600)
observed - expected2110-26-5
(observed-expected)244110067625
(observed-expected)2 / expected0.490 = (441/900)0.333 = (100/300)2.245 = (676/300)0.25 = (25/100)
Sum Χ2 = 3.3.26

Degree of freedom is the number of events (or categories) minuses one (4 categories in this example '9, 3, 3, & 1, so the degree of freedom is 3).

Question. Do you accept or reject the hypothesis (the fly has AaBb genotype) in the above example?