StatLabStudent EditionUser guideGalleryFeaturesAbout

Crosstabs and chi-square

Crosstabs cross-tabulates two categorical variables and tests whether they are associated with Pearson's chi-square (plus continuity correction and Fisher's exact test for 2×2 tables), with Phi and Cramér's V as effect sizes.

Menu: Analyze → Descriptive Statistics → Crosstabs…

When should I use Crosstabs and chi-square?

What are the assumptions?

How do I run it in StatLab?

  1. Choose the row and column variables.
  2. Keep chi-square ticked; add row or column percentages to describe the pattern.
  3. Optionally add expected counts, adjusted residuals and a clustered bar chart.

How do I read the output?

OutputMeaning
Pearson Chi-SquareValue, df and asymptotic p. The main test.
Continuity CorrectionYates-corrected chi-square (2×2 only); more conservative.
Likelihood RatioG-test alternative; usually agrees with Pearson.
Fisher's Exact TestExact p for 2×2 tables; use when expected counts are small.
Linear-by-Linear AssociationTrend test when both variables are ordered numeric codes.
Phi / Cramér's VEffect size 0–1. Rough guide for V: .10 small, .30 medium, .50 large (for df = 1).
Adjusted ResidualCells beyond ±1.96 contribute most to a significant result.
Footnote bHow many cells have expected count < 5 — check it before trusting the asymptotic p.

Worked example

Crosstab smoker by gender in the bundled sample dataset (File → Sample dataset: 150 survey respondents with gender, programme group, age, pre/post test scores, five satisfaction items, income, smoking and education): χ²(1) = 0.09, p = .765; 0 cells have expected counts below 5.

How would I report it in APA style?

A chi-square test of independence showed no significant association between smoking and gender, χ²(1, N = 150) = 0.09, p = .765, Cramér's V = .02.

Numbers above were computed by StatLab’s validated engine from the sample dataset when this page was built.

What are common mistakes?

Where can I see it worked through?

Open StatLab   All guide topics