The one-sample Kolmogorov-Smirnov (K-S) test compares your data with a reference distribution, usually the normal. Its statistic, D, is the largest gap between the share of your sample at or below each value and the share the reference distribution expects there. The write-up is one line, but that line hides a choice most people do not know they are making: whether the normal curve's mean and SD were fixed in advance or estimated from the same data. The two cases need different p values, and on the example below they give opposite verdicts from the same D. This guide shows both cases, the APA format, what SPSS prints, and how the K-S test compares with Shapiro-Wilk.
What you need before you write a single word
- The statistic D and the sample size n, which serves as the df in parentheses.
- The exact p value, and which version produced it: the plain K-S test or the Lilliefors-corrected one.
- What the data were compared with. A normal distribution with the mean and SD estimated from the sample (the usual normality check), or a distribution fixed in advance, such as published norms.
- What you did next if normality was rejected: a transformation, a non-parametric test, or a robust method.
Which K-S test are you reporting?
| You compared your data with... | Run | Report |
|---|---|---|
| A normal curve with a mean and SD set in advance (published norms, a theory) | The one-sample K-S test | D(n) and its p |
| A normal curve with the mean and SD estimated from the same sample | Lilliefors' version of the K-S test | D(n) and the Lilliefors p |
The statistic D is identical in both rows. Only the p value changes. Estimating the mean and SD from the sample moves the normal curve toward the data, so gaps come out smaller than the plain K-S tables assume and the plain p is too high. Lilliefors (1967) worked out the correct p for this case.
Where each version lives in software:
- SPSS: the Kolmogorov-Smirnov columns of the Tests of Normality table (Analyze > Descriptive Statistics > Explore, "Normality plots with tests") are Lilliefors-corrected; the footnote says "Lilliefors Significance Correction".
- R:
ks.test(x, "pnorm", mean(x), sd(x))gives the plain p;nortest::lillie.test(x)gives Lilliefors'. - Python:
scipy.stats.kstestgives the plain p;statsmodels.stats.diagnostic.lillieforsgives Lilliefors'.
Above .10 the Lilliefors p comes from approximations that can differ in the third decimal: for the accuracy scores below, R's lillie.test() (and KyroStat) give .753, statsmodels' default table gives .757. Both are far above .05.
The APA 7 format template
A Kolmogorov-Smirnov test [with Lilliefors correction] indicated that [variable] [did not depart / departed] significantly from a normal distribution, D(n) = .XX, p = .XXX.
Formatting rules:
- Italicize D and p. Put n (not n − 1) in the parentheses.
- No leading zero on D or p: D cannot exceed 1. Round D to two decimals (.103 becomes .10); keep three if your journal wants the software value.
- Exact p to three decimals, or p < .001.
- Name the version. "K-S test" alone does not tell the reader whether the p is corrected.
- Greek letters for fixed population values stay upright: μ = 50, σ = 10.
Worked example 1: comparing a sample with published norms
An anxiety measure is scored as T-scores, normed to a mean of 50 and SD of 10 in the general population. A clinic tested whether its 60 patients' scores follow those norms. The mean and SD are fixed in advance, so the plain one-sample K-S test is the right one.
The patients had M = 53.91, SD = 9.82. The largest gap was at a score of 45.7: 13% of patients scored below it, where the norms place 33% of people. That gap is D = .20. Its p of .014 comes from the exact distribution of D, which R's ks.test() and SciPy's kstest use at this sample size; software that uses the large-sample approximation prints .016.
Write it:
A one-sample Kolmogorov-Smirnov test showed that the clinic patients' anxiety T-scores (M = 53.91, SD = 9.82) did not follow the population norms (μ = 50, σ = 10), D(60) = .20, p = .014. Fewer patients than expected had low scores: 35% scored at or below 50, against 50% in the norm population.
D tells you the distributions differ, not how. Add the descriptive numbers that show the direction, as the second sentence does.
Worked example 2: a normality check before a t test
A lab measured task completion time (seconds) and accuracy (%) for 100 participants and checked both for normality before choosing its tests. The mean and SD were estimated from the sample, so the Lilliefors-corrected p applies.
| Completion time (s) | Accuracy (%) | |
|---|---|---|
| M (SD) | 43.14 (12.55) | 71.51 (8.57) |
| Mdn | 41.00 | 71.70 |
| K-S D | .103 | .051 |
| Plain K-S p (wrong here) | .222 | .945 |
| Lilliefors p | .011 | .753 |
| Shapiro-Wilk W, p | .958, .003 | .990, .629 |
Look at completion time. The plain K-S p of .222 says "normal enough"; the Lilliefors p of .011 says the distribution departs from normal. Same data, same D, opposite conclusions. Because the mean and SD came from these 100 times, .011 is the correct value; reporting .222 would be a real error, not a rounding issue. The mean sitting above the median (43.14 vs 41.00 s) shows the long right tail behind the result.
Write it:
Normality was assessed with the Kolmogorov-Smirnov test with Lilliefors correction. Completion times departed from a normal distribution, D(100) = .10, p = .011, with a long right tail (M = 43.14 s, Mdn = 41.00 s), so group comparisons on completion time used the Mann-Whitney U test. Accuracy scores did not depart from normality, D(100) = .05, p = .753.
The same results, laid out as SPSS's Tests of Normality table
Tests of Normality
| Kolmogorov-Smirnovᵃ Statistic | df | Sig. | Shapiro-Wilk Statistic | df | Sig. | |
|---|---|---|---|---|---|---|
| Completion time | .103 | 100 | .011 | .958 | 100 | .003 |
| Accuracy | .051 | 100 | .200* | .990 | 100 | .629 |
*. This is a lower bound of the true significance.
a. Lilliefors Significance Correction
SPSS stops reporting the Lilliefors p at .200 and marks it with an asterisk: the true value is at least .200 (here it is about .75). Write p > .200, not p = .200. A Sig. of .000 anywhere in this table becomes p < .001.
Reporting several variables or groups in a table
Table 1
Tests of Normality for the Study Variables
| Variable | n | D | p | W | p |
|---|---|---|---|---|---|
| Completion time (s) | 100 | .10 | .011 | .96 | .003 |
| Accuracy (%) | 100 | .05 | .753 | .99 | .629 |
Note. D = Kolmogorov-Smirnov statistic with Lilliefors-corrected p; W = Shapiro-Wilk statistic.
For a t test or an ANOVA, check each group separately (one row per group); for a regression, check the residuals rather than the raw outcome.
Why Shapiro-Wilk usually catches more
To see how the tests behave, we drew 2,000 samples of 50 from a normal distribution and 2,000 from a moderately right-skewed one (a gamma distribution with skewness 1.0), and ran each test at α = .05:
| Test | Normal data: flagged as non-normal | Skewed data: flagged as non-normal |
|---|---|---|
| Plain K-S (mean and SD estimated) | 0.0% (0 of 2,000) | 2.1% |
| K-S with Lilliefors correction | 5.2% | 40.6% |
| Shapiro-Wilk | 5.0% | 70.4% |
The plain K-S test with estimated parameters almost never rejects, whatever the data: it missed the skew in 98% of samples. Lilliefors' correction restores the 5% false-positive rate, and Shapiro-Wilk detects the skew most often. That is why many reviewers prefer Shapiro-Wilk for a normality check (see how to report a Shapiro-Wilk test). The K-S test keeps its place for comparing data with a fully specified distribution, as in Example 1, and many authors report both, as SPSS prints them together.
Mistakes reviewers catch
- The plain p after estimating the mean and SD. The commonest K-S error, and as Example 2 shows it can flip the verdict.
- "p = .200" from SPSS. It is a lower bound; write p > .200.
- No version named. Write "Kolmogorov-Smirnov test with Lilliefors correction" or "Lilliefors test".
- Reporting a "Kolmogorov-Smirnov Z". Some older SPSS output printed Z = D × √n. Report D.
- A leading zero: D = 0.10 should be D = .10.
- Treating a non-significant result as proof of normality. With small samples the test has little power; look at a Q-Q plot too.
- Treating a significant result at large n as a disaster. With thousands of cases, trivial departures are significant; say how large the departure is (skewness, the plot) before changing the analysis.
Let KyroStat check normality
KyroStat runs the one-sample Kolmogorov-Smirnov test against a normal with the mean and SD you give, and says so when they were estimated from the sample instead. It also runs Lilliefors' test and Shapiro-Wilk, each with its APA sentence. Upload your data to run them on your own variables.
Frequently asked questions
Is the Kolmogorov-Smirnov test the same as the Lilliefors test? They share the statistic D. Lilliefors' test is the K-S test for the case where the normal curve's mean and SD are estimated from the sample, with p values that account for that.
Should I report Kolmogorov-Smirnov or Shapiro-Wilk? For a routine normality check, Shapiro-Wilk is more sensitive (70% against 41% in the simulation above). If your field or journal expects K-S, report the Lilliefors version, or both.
What df do I put in D(df)? The sample size: D(100) for 100 cases. SPSS's df column shows the same number.
How do I report a two-sample Kolmogorov-Smirnov test? The same way, with both group sizes: "a two-sample Kolmogorov-Smirnov test showed that the two groups' distributions differed, D = .XX, p = .XXX (n₁ = XX, n₂ = XX)". It compares whole distributions, not just medians.
My data failed the test. What now? Say what you did: a transformation, a non-parametric test such as the Mann-Whitney U test, or a method that does not assume normality. The assumptions guide lists the options for each test.
References
Lilliefors, H. W. (1967). On the Kolmogorov-Smirnov test for normality with mean and variance unknown. Journal of the American Statistical Association, 62(318), 399–402. https://doi.org/10.1080/01621459.1967.10482916
Related guides
- How to report a Shapiro-Wilk test in APA 7: the other normality test in the same SPSS table.
- How to check statistical test assumptions: what to check for each test and what to do when a check fails.
- How to report a Mann-Whitney U test in APA 7: the usual fallback when normality fails for two groups.
- How to report descriptive statistics in APA 7: means, medians and SDs that show the shape.
- Which statistical test should I use?: the test picker.