Not sure whether your data are roughly normal? Check with the normality test (Shapiro–Wilk + Q-Q plot). Prefer to read? See the full guide to choosing a statistical test → or browse all calculators →.

Three questions decide the test

Almost every choice between common statistical tests comes down to three questions, which is what the chooser above asks:

  1. What is your goal? Comparing groups, measuring a relationship between two variables, or predicting one variable from others.
  2. What type is your outcome variable? Continuous measurements (height, score, time), categories (yes/no, brand chosen), or ranks.
  3. How are the groups related? Independent groups (different people in each) or paired data (the same people measured twice, or matched pairs).

Quick reference

Your situationUsual testIf assumptions fail
Compare one group's mean with a known valueOne-sample t-testWilcoxon signed-rank test
Compare means of two independent groupsTwo-sample t-test (Welch)Mann–Whitney U test
Compare the same people before and afterPaired t-testWilcoxon signed-rank test
Compare means of three or more groupsOne-way ANOVAKruskal–Wallis test
Compare two proportions (e.g. conversion rates)Two-proportion z-testFisher's exact test (small samples)
Is there an association between two categorical variables?Chi-square test of independenceFisher's exact test (small expected counts)
Strength of a relationship between two continuous variablesPearson correlationSpearman rank correlation
Predict a continuous outcome from one or more predictorsLinear regressionTransform the outcome or use robust regression
Is an observed success count consistent with a known rate?Binomial test—
Compare two classifiers on the same test setMcNemar's testPaired bootstrap

Parametric or nonparametric?

Parametric tests such as the t-test and ANOVA compare means and assume the data in each group are roughly normal. With moderate samples (around 30 or more per group) they are robust to mild skew because of the Central Limit Theorem. Nonparametric tests such as Mann–Whitney and Kruskal–Wallis compare ranks instead, so they cope with strong skew, outliers and ordinal data such as Likert ratings, at the cost of a little power when the data really are normal. If your sample is small and clearly skewed, or your outcome is a rating scale, the nonparametric option is usually safer.

Two common traps

For a longer walkthrough with a flowchart, read the guide to choosing a statistical test.