Skip to content
Verify InstituteA little more certainty.No account required
Methods and assumptions documented

Chi-Square Goodness-of-Fit Calculator

Run a chi-square goodness-of-fit test comparing observed category counts with expected counts.

Enter quantities in the labelled units. Unit changes keep the entered number; calculate again.

Loading calculator… If this message remains, reload the page.

Assumptions

Expected counts should generally be at least 5 per category.

Calculations run on your device. Input values are not placed in the URL or sent to analytics.

HOW THE CALCULATION WORKS

Transparent chi-square goodness-of-fit calculator method

  1. χ² = Σ (observed − expected)² ÷ expected.
  2. Degrees of freedom = categories − 1.
  3. p-value = upper tail of the chi-square distribution; expected values are scaled to the observed total.

Worked example

Observed 48, 35, 15, 2 against expected 40, 40, 15, 5: χ² = 4.025 with 3 degrees of freedom, p ≈ 0.259.

Defaults and assumptions

Limitations

Precision and rounding

Supported arithmetic uses exact fractions. Formulas involving logarithms, trigonometry, statistical functions or simulations can use numerical approximations; storing an approximation as a fraction does not make it exact. Decimal display rounds to at most 6 fractional places, so very small values can appear as approximately zero. Time displays round to the nearest second where shown. Whole-item rounding follows the stated formula.

Sources

Use the assumptions, worked example and sources to interpret your result. Estimates do not replace professional advice.

How to use this calculator

  1. Enter the measured quantities in the labelled units; inspect any named customer defaults.
  2. Check the units, dates and selected options. Where a tool asks for a rate, price or product specification, use a value appropriate to your situation.
  3. Calculate and compare the result, exact details, assumptions and worked example.

Common questions

Are the example values recommendations?

No. They demonstrate the arithmetic. Use measurements, product labels and supplier information appropriate to your situation.

What happens when I change units?

The entered number stays the same and is reinterpreted in the new unit. The old result is cleared; calculate again.

Are inputs sent to a server?

No. Calculations stay in your browser. A calculation record is downloaded only when you request it.

Report a problem or suggest a calculator

Found a confusing result, a missing option, or an idea for a new calculator? Send it privately to the site owner.

Opening the form loads Cloudflare Turnstile, a spam check that processes connection and device information. Privacy details.

Related tools