Expected counts describe what a table would look like under a model of independence while retaining its row and column totals. They are model-based reference counts, not new observations.
Construct a table from its margins
Suppose a two-row, three-column table contains 100 observations. Row totals are 40 and 60; column totals are 30, 50, and 20. Under independence, each row has the same expected column proportions: 30%, 50%, and 20%.
| Row | Category A | Category B | Category C | Row total |
|---|---|---|---|---|
| First row | 12 | 20 | 8 | 40 |
| Second row | 18 | 30 | 12 | 60 |
| Column total | 30 | 50 | 20 | 100 |
For example, the first cell is . The expected counts reproduce every margin. Dividing 100 equally among six cells would ignore the differing category frequencies.
Compare observed and expected counts
Given actual observed counts , Pearson's statistic is
For a standard independence test in an table, the reference degrees of freedom are . This example has two degrees of freedom. The margins alone do not supply the observed cell counts, so they do not determine a test statistic or p-value.
Check the sampling conditions
Use counts of observations in mutually exclusive categories and ensure the observations are independent. A common introductory adequacy rule requires every expected count to be at least five; all six expected counts here satisfy it. Sparse tables may require an exact or simulation-based method rather than an unexamined chi-square approximation.
Kaugnay na tanong
Gamitin ang kaalamang ito
Gamitin ang gabay sa konsepto para maunawaan ang pangangatwiran, pagkatapos ay bumalik sa kumpletong tanong at may nilutas na sagot.
Select the Null Hypothesis for a Test of Independence: H₀ and H₁Mga Source
Sinusuportahan ng mga reference na ito ang mga pangunahing konsepto at hangganan ng interpretasyong ipinaliwanag sa itaas.