Wauvel

Excel like a finance pro.

← The library

Statistical function

CHISQ.TEST

Returns the p-value of a chi-squared test of independence.

Rarely usedDifficulty 1550 · AdvancedUsage rank #427 of 520
Practice · 2 questions →

When to use it

The p-value of a chi-squared test of independence, comparing an observed table to the expected counts. Low p means the rows and columns are related.

The shape of it

Syntax
=CHISQ.TEST(actual_range, expected_range)

Worked examples

  • 2 by 2 table

    =CHISQ.TEST({30,20;20,30},{25,25;25,25}) 0.045500264

    A 2×2 table where each cell differs from expected by 5: chi-squared 4 on 1 degree of freedom.

  • From ranges

    =CHISQ.TEST(B2:C3,E2:F3) 0.0455

    The same test with the observed and expected tables on the sheet.

  • Larger table

    =CHISQ.TEST(B2:D4,E2:G4) 0.31

    A 3×3 table with 4 degrees of freedom: no evidence of a relationship.

Worth knowing

  • Expected counts are row total × column total / grand total; build them with formulas.
  • Cells with expected counts below 5 make the test unreliable.
  • Degrees of freedom are (rows - 1) × (columns - 1).

Where it goes wrong

  • #N/A when the two tables differ in shape.
  • Works on counts, not percentages.

Related

Learn the moves here — or let Wauvel run them on your numbers.

Meet your AI CFO →

One CFO-grade Excel tip a week

A short, practical email for finance operators — functions, shortcuts, and the moves that save an afternoon. Free, unsubscribe anytime.