Chi-Square Goodness-of-Fit Calculator
Test if observed experimental counts differ significantly from theoretical expected counts (e.g. Mendelian ratios 3:1 or 9:3:3:1).
Category Data
Input Observed and Expected counts. Leave rows empty to exclude categories.
Test Results
Expert Tip
A non-significant result (p > 0.05) indicates that any difference between your observed experimental data and the theoretical model can be attributed to random chance alone.
Methodology & Equations
Chi-Square Test Equation
The goodness-of-fit test measures how well observed counts fit expected counts:
Steps of Analysis
1. State null hypothesis (no difference between observed and expected).
2. Compute expected values based on target ratios.
3. Calculate the χ2 statistic.
4. Compare χ2 to critical values (using df = categories - 1).
How to Run a Chi-Square Goodness-of-Fit Test: Step-by-Step
Below is a step-by-step example using observed counts of 290 and 110 individuals, with expected values of 300 and 100:
Calculate Category 1 Difference
Find difference squared divided by expected:
(290 - 300)2 / 300 = (-10)2 / 300 = 100 / 300 = 0.333.
Calculate Category 2 Difference
Find difference squared divided by expected:
(110 - 100)2 / 100 = 102 / 100 = 100 / 100 = 1.000.
Sum & Determine df
Sum the values: χ2 = 0.333 + 1.000 = 1.333.
Degrees of Freedom (df) = 2 categories - 1 = 1.
At α = 0.05 and df = 1, critical value is 3.841. Since 1.333 ≤ 3.841, the difference is not statistically significant (p = 0.248).
Related Calculators
View All Biology Tools →Hardy-Weinberg Equilibrium
Test whether population genotypes conform to Hardy-Weinberg equilibrium.
Allele Frequency Calculator
Determine dominant and recessive allele frequencies from observed genotype counts.
Monohybrid Cross
Predict genotypic and phenotypic ratios of offspring for a single gene.