Hypothesis Testing Calculator — Z, T, Chi-Square Tests

Run z-tests, t-tests and chi-square tests with p-values and conclusions.

About this calculator

A hypothesis testing calculator performs one-sample and two-sample t-tests, z-tests, chi-square tests, and ANOVA. Hypothesis testing is the framework for deciding whether observed differences in data are likely due to a real effect or just random sampling variation.

Set a null hypothesis (no effect), an alternative hypothesis (there is an effect), and a significance level (usually α = 0.05). Calculate a test statistic and its p-value. If p < α, reject the null. Critically, "fail to reject" is not the same as "accept" — it just means you don't have enough evidence either way.

Formula

t = \frac{\bar{x} - \mu_0}{s / \sqrt{n}}

  • — Sample mean
  • μ₀ — Null hypothesis mean
  • s — Sample standard deviation
  • n — Sample size
  • df — Degrees of freedom = n − 1

Worked example

Inputs: Battery life: claimed mean 100 h. Sample of 16 batteries: mean 95 h, sd 8 h.

  1. H₀: μ = 100; H₁: μ < 100
  2. t = (95 − 100) / (8/√16) = −5 / 2 = −2.5
  3. df = 15, critical t (α = 0.05, one-tailed) = −1.753
  4. t = −2.5 < −1.753 → reject H₀
  5. Conclude: mean life is significantly less than 100 h

Frequently asked questions

What is a p-value?

The probability of observing data as extreme or more extreme than what you actually saw, assuming the null hypothesis is true. A p-value of 0.03 means: if the null is true, only 3% of similar experiments would produce data this far from the null. Lower p-value = stronger evidence against the null. Note: p-value is NOT the probability that the null is true — a common but serious misinterpretation.

What is the difference between statistical and practical significance?

Statistical significance (p < 0.05) means the effect is unlikely due to chance. Practical significance asks whether the effect size is large enough to matter. With huge samples, you can get statistically significant differences that are too small to be useful (e.g. a 0.01% improvement in conversion). Always report and interpret the effect size alongside the p-value.

Related calculators

Descriptive Stats Probability Regression

More calculators

EMI Calculator Mortgage Calculator SIP Calculator Compound Interest GST / VAT Calculator Salary Calculator Unit Converter Currency Converter Scientific Calculator Concrete Calculator Paint Calculator Tile Calculator Calorie / TDEE Body Fat Macro Calculator O-Ring Sizes Bolt & Nut Sizes Pipe Sizes Wire Gauge AWG Needle Gauge Chart IV Cannula Sizes Suture Sizes Catheter French Sizes Drug Dosage See all 90+ calculators ›