Violation of the normality assumption means your data (or your model’s residuals) do not follow a bell-shaped, normal distribution. This matters for some statistical tests and confidence intervals, but it is not a fatal flaw for many others. The key is knowing which methods depend on normality and which do not, and how to check and adapt when the assumption is broken.
Formula
The normality assumption is often checked using skewness and kurtosis. For a sample of size n, the standard errors are:
SEskewness = √(6/n)
SEkurtosis = √(24/n)
where n is the sample size. The Z-scores are then:
Zskewness = (sample skewness) / SEskewness
Zkurtosis = (sample excess kurtosis) / SEkurtosis
Excess kurtosis is the kurtosis minus 3 (so a normal distribution has excess kurtosis = 0). A rule of thumb: if |Z| > 1.96, the skewness or kurtosis is significantly different from normal at the 5% level.
Worked Example
Suppose you have n = 30 observations, sample skewness = 0.5, and sample excess kurtosis = 0.5. Using the defaults from the calculator:
SEskewness = √(6/30) = √0.2 = 0.4472
SEkurtosis = √(24/30) = √0.8 = 0.8944
Zskewness = 0.5 / 0.4472 = 1.118
Zkurtosis = 0.5 / 0.8944 = 0.559
Both Z-scores are below 1.96, so no significant violation is detected. The calculator gives the same values: zskew = 1.118, zkurt = 0.559.
Assumptions
- The sample is drawn independently from the population.
- The sample size is not extremely small (n < 5 makes these estimates unstable).
- Skewness and kurtosis are computed using the standard sample formulas (adjusted for bias).
- This method only checks univariate normality; it does not check multivariate normality.
Why Normality Is Assumed
Many classical statistical methods are built on the normal distribution because of the Central Limit Theorem and the mathematical convenience of the bell curve. When you assume normality, you can derive exact sampling distributions for test statistics like the t-statistic or F-statistic. This allows you to calculate p-values and confidence intervals without simulation.
However, real data rarely are perfectly normal. Heights, measurement errors, and many biological variables are approximately normal, but income, reaction times, and chemical concentrations often are skewed. The question is not whether your data are exactly normal (they are not), but whether the deviation is small enough that the method still works reliably.
How to Detect a Violation
You can check normality visually and statistically:
- Histogram: Look for a bell shape, but beware – histograms can be misleading with small samples.
- Q-Q plot: Plot your data quantiles against theoretical normal quantiles. Points that follow a straight line suggest normality; systematic curves indicate skewness or heavy tails.
- Shapiro-Wilk test: A common statistical test for normality. It has good power but is sensitive to large samples – with n > 1000, even tiny deviations become significant.
- Kolmogorov-Smirnov test: Also used, but less powerful than Shapiro-Wilk for most situations.
- Skewness and kurtosis Z-scores: As in the calculator above, check if skewness or kurtosis deviate significantly from 0.
Remember: statistical tests answer “is there evidence of non-normality?” but they don’t tell you whether the violation matters for your analysis. A significant Shapiro-Wilk test with n=500 may be irrelevant if your t-test is robust.
When Violation Matters
Normality matters most for:
- Small samples (n < 30): The Central Limit Theorem hasn’t kicked in, so the sampling distribution of the mean may not be normal.
- Confidence intervals for the mean: The t-interval assumes the sample mean is normally distributed. With skewed data and small n, coverage can be less than 95%.
- Hypothesis tests on means: The t-test is fairly robust to moderate non-normality, but with strong skewness or outliers, the Type I error rate can inflate.
- Linear regression: The residuals (not the raw data) are assumed normal for inference on coefficients. If residuals are heavily skewed, p-values and confidence intervals may be unreliable.
- ANOVA: Similar to t-tests, ANOVA assumes normal residuals within groups.
When normality is violated, the test may still be valid if the sample is large enough (thanks to the Central Limit Theorem) or if the violation is mild. The real danger is with small samples and extreme skewness or outliers.
Common Problems and Misconceptions
Misconception 1: “I need to transform my data to make it normal.” Not always. If you only need to estimate a mean, the raw mean is still unbiased even if data are skewed. Transformations (log, square root, Box-Cox) can help for inference, but they change the interpretation – you’re then testing the transformed mean, not the original.
Misconception 2: “If the p-value is >0.05, my data are normal.” Failing to reject normality does not prove normality; it just means there isn’t strong evidence against it. With small samples, the test has low power, so non-normality may go undetected.
Misconception 3: “Normality refers to the raw data.” In regression and ANOVA, the assumption is about the residuals, not the dependent variable itself. You can have a skewed outcome variable but normal residuals after including predictors.
Misconception 4: “All parametric tests require normality.” Many tests (e.g., proportion tests, chi-square tests) rely on other distributions. Also, robust methods like Welch’s t-test are less sensitive to unequal variances and non-normality.
Alternatives and Robust Methods
If normality is violated, you have several options:
- Non-parametric tests: Use the Wilcoxon rank-sum test instead of the two-sample t-test, or the Kruskal-Wallis test instead of one-way ANOVA. These tests rank the data and do not assume normality.
- Permutation tests: These resample the data to build a null distribution, making no normality assumption. They are flexible and exact for any sample size.
- Bootstrap confidence intervals: Resample with replacement to estimate the sampling distribution of the statistic. This works for means, medians, correlations, etc.
- Robust statistics: Use the median instead of the mean, or trimmed means. These are less affected by outliers and skewness.
- Transformations: Log, square root, or Box-Cox transformations can make data more symmetric, but interpret results on the transformed scale.
For regression, you can use robust standard errors (e.g., Huber-White) that are valid even with non-normal residuals, or use generalized linear models that allow other error distributions (e.g., Poisson for count data).
Frequently Asked Questions
Does the t-test require normal data?
The t-test assumes that the sample mean is normally distributed. For large samples (n > 30), the Central Limit Theorem ensures this even if the original data are not normal. For small samples, the t-test is fairly robust to mild non-normality, but with strong skewness or outliers, you should consider a non-parametric alternative like the Wilcoxon test.
What is the difference between testing normality of data vs residuals?
For a simple one-sample test, you check the data itself. For regression or ANOVA, the assumption is that the errors (residuals) are normally distributed, not the dependent variable. You should plot and test the residuals after fitting the model.
Can I use a log transformation if my data are skewed?
Yes, a log transformation is common for positively skewed data (e.g., concentrations, reaction times). But remember that you are then making inferences about the geometric mean, not the arithmetic mean. Also, log transformation requires all values to be positive; if you have zeros, you might add a small constant.
What sample size makes normality not matter?
There is no magic number, but many textbooks suggest n > 30 for the Central Limit Theorem to make the sampling distribution of the mean approximately normal. However, for heavily skewed distributions, you may need much larger samples (n > 100 or more). Check with a simulation or use robust methods if you are unsure.
Is the Shapiro-Wilk test the best way to check normality?
Shapiro-Wilk is powerful and recommended for small to moderate sample sizes (n < 5000). For very large samples, it can detect trivial deviations that have no practical impact. In those cases, rely more on visual Q-Q plots and consider the sample size.
What should I do if my data are not normal but I need to compare means?
Use a non-parametric test like the Mann-Whitney U test (for two groups) or Kruskal-Wallis (for more than two groups). These tests compare medians rather than means, so they answer a slightly different question. Alternatively, use a bootstrap t-test that does not assume normality.