Chi-Square Test Calculator

Test goodness of fit between observed and expected frequencies. Calculate χ² statistic, p-values, and determine statistical significance for genetics experiments.

Select the number of categories (2-10)
Enter observed and expected frequencies for each category
Category A
-
Category B
-
Category C
-
Category D
-
Select the significance level for hypothesis testing

Chi-Square Statistics

χ² Value
0.000
Degrees of Freedom
0
Critical Value
0.000
P-Value
0.000

Hypothesis Test Result

Data Comparison

Observed
Expected

What is Chi-Square Test?

The chi-square (χ²) test is a statistical test used to determine if observed frequencies differ significantly from expected frequencies. In genetics, it's commonly used to test if experimental results match predicted Mendelian ratios.

χ² = Σ [(O - E)² / E]

O = Observed frequency, E = Expected frequency

How to Use This Calculator

  1. Select the number of categories
  2. Enter observed counts for each category
  3. Enter expected counts (or ratios)
  4. Choose significance level (usually 0.05)
  5. Click "Calculate" to see results

Interpreting Results

Chi-Square Value: Higher values indicate greater difference between observed and expected.

P-Value: Probability of getting these results by chance. If p < α, reject null hypothesis.

Conclusion:

  • Accept: Data fits expected ratio (p ≥ α)
  • Reject: Data differs significantly (p < α)

Degrees of Freedom

Degrees of freedom (df) = number of categories - 1

Example:

  • 2 categories → df = 1
  • 4 categories → df = 3
  • 9 categories → df = 8

Example: Mendelian 3:1 Ratio

Testing a monohybrid cross:

Observed: 315 dominant, 108 recessive
Expected: 3:1 ratio (317.25, 105.75)
χ² = 0.072, df = 1, p > 0.05
Result: Accept (fits 3:1 ratio)

Common Applications

  • Testing Mendelian ratios (3:1, 9:3:3:1)
  • Hardy-Weinberg equilibrium testing
  • Linkage analysis
  • Sex ratio analysis
  • Genetic cross validation