What are the expected-count conditions for a chi-square test, and what do you do when cells are too sparse?

Quick Overview

Asks for the expected-count conditions behind the chi-square test and what to do when a contingency table has cells with very low expected counts. It tests whether you understand when the chi-square approximation holds and how to get a trustworthy p-value from sparse data.

What are the expected-count conditions for a chi-square test, and what do you do when cells are too sparse?

Role: Data Scientist

Category: Statistics & Math

Difficulty: easy

Interview Round: Other

What are the expected-count conditions for a chi-square test, and what should you do if some cells have very low expected counts? ```hint What can you change Think about why the test statistic only approximately follows a chi-square distribution. Then list what you could change when the approximation is poor: the table, the sample, or the way the p-value is computed. ``` ### What a Strong Answer Covers - How a cell's expected count is computed, and why the condition is stated on expected counts - The usual rule of thumb (Cochran's rule) and its relaxed form - Why sparse cells make the chi-square p-value unreliable - The remedies for a sparse table and when each one fits - Pitfalls when fixing sparsity, such as collapsing categories after seeing the result ### Follow-up Questions - How does Fisher's exact test compute its p-value, and what does conditioning on the margins assume? - What does Yates' continuity correction do, and why is it rarely recommended today? - How would you get a simulated p-value for a 5x4 table with several sparse cells? - Does the same expected-count rule apply to a chi-square goodness-of-fit test?

Overview: Asks for the expected-count conditions behind the chi-square test and what to do when a contingency table has cells with very low expected counts. It tests whether you understand when the chi-square approximation holds and how to get a trustworthy p-value from sparse data.

General logo
General
Nov 25, 2026
easyData ScientistOtherStatistics & Math
0
0

What are the expected-count conditions for a chi-square test, and what should you do if some cells have very low expected counts?

What a Strong Answer Covers Guidance

  • How a cell's expected count is computed, and why the condition is stated on expected counts
  • The usual rule of thumb (Cochran's rule) and its relaxed form
  • Why sparse cells make the chi-square p-value unreliable
  • The remedies for a sparse table and when each one fits
  • Pitfalls when fixing sparsity, such as collapsing categories after seeing the result

Follow-up Questions Guidance

  • How does Fisher's exact test compute its p-value, and what does conditioning on the margins assume?
  • What does Yates' continuity correction do, and why is it rarely recommended today?
  • How would you get a simulated p-value for a 5x4 table with several sparse cells?
  • Does the same expected-count rule apply to a chi-square goodness-of-fit test?