Khiin neliö -testin laskin

Testaa kategoristen muuttujien välisiä suhteita khiin neliö -analyysillä

Enter the observed frequencies for each category (separated by commas or spaces)

If not provided, assumes uniform distribution (equal expected frequencies)

Common values: 0.05 (5%), 0.01 (1%), 0.10 (10%)

Tulokset

Syötä arvot ja klikkaa Laske nähdäksesi tuloksen.

Chi-Square Test

The chi-square test is used to test if observed frequencies differ significantly from expected frequencies. It is commonly used for:

  • Goodness-of-Fit Test: Tests if observed data fits an expected distribution
  • Test of Independence: Tests if two categorical variables are independent
  • Test of Homogeneity: Tests if different populations have the same distribution

Key Formulas:

  • χ² = Σ[(O - E)² / E], where O = observed, E = expected
  • Degrees of Freedom: df = number of categories - 1
  • If p-value < α: Reject null hypothesis (significant difference)
  • If p-value ≥ α: Fail to reject null hypothesis (no significant difference)

The test assumes that expected frequencies are at least 5 in each category for reliable results. For smaller expected frequencies, consider combining categories or using Fisher's exact test.

\(\chi^2 = \sum \frac{(O - E)^2}{E}, df = k - 1\)

Worked Examples

Example 1

\(\text{Test if die is fair: } O = [30,20,25,25,22,28], E = [25,25,25,25,25,25]\)

Example 2

\(\text{Test product preferences: } O = [45,30,25], E = [33.3,33.3,33.3]\)
Chi-Square Test Calculator | MathCalcLab | MathCalcLab