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.

Category Name
Observed (O)
Expected (E)

Test Results

Chi-Square (χ2) 1.333
Degrees of Freedom (df) 1
p-value 0.248
Stat. Significance Not Significant (p > 0.05)
๐Ÿ’ก

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:

χ2 = Σ [ (O - E)2 / E ]
๐Ÿ”ฌ

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:

1

Calculate Category 1 Difference

Find difference squared divided by expected:
(290 - 300)2 / 300 = (-10)2 / 300 = 100 / 300 = 0.333.

2

Calculate Category 2 Difference

Find difference squared divided by expected:
(110 - 100)2 / 100 = 102 / 100 = 100 / 100 = 1.000.

3

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 →