← Blog

The GRIM test, explained

How a single line of arithmetic can prove that a reported mean is impossible — with a worked example, the exact conditions under which it applies, and where it goes wrong.

08 JUL 20264 MIN READ GRIMmethodsforensics

Most statistical errors in published papers are invisible. The GRIM test is remarkable because it makes one class of them provable — not suspicious, not unlikely, but arithmetically impossible — using nothing more than a reported mean and a sample size.

The idea in one paragraph

If a variable is made of whole numbers — a count, a Likert response, a number of correct answers — then the mean of N of them is a fraction with denominator N. It cannot be anything else. For 20 participants, the only possible means are multiples of 1/20 = 0.05: 3.40, 3.45, 3.50, and so on. A paper reporting a mean of 3.43 for 20 participants has reported a number that no dataset can produce.

That is the whole test. Brown and Heathers named it GRIM — Granularity-Related Inconsistency of Means — and published it in 2017.

A worked example

Suppose a study reports that 20 participants rated their mood at M = 3.43 on a 1–7 scale.

The sum of 20 integers is an integer, call it S. The mean is S / 20. So the achievable means near 3.43 are:

Sum S Mean
68 3.40
69 3.45
70 3.50

Now account for rounding. A printed 3.43 means the true value fell in [3.425, 3.435). Neither 3.40 nor 3.45 falls inside that window. There is no integer S that produces it.

The reported mean is impossible. Something else is wrong: the sample size, the mean itself, or the data.

When the test actually applies

GRIM is only informative under three conditions, and every one of them matters.

1. The underlying data must be integers. A mean height in centimetres, measured to one decimal, has no such granularity constraint. Applying GRIM to continuous data produces nonsense.

2. The sample size must be small enough. The achievable means sit 1/N apart. If you report to two decimals, GRIM tells you nothing once N ≥ 100, because the grid is finer than the printing precision. The general condition is:

N × items < 10 ^ (decimal places reported)

3. You must know N exactly. Missing data is the single most common reason a GRIM “failure” turns out to be innocent. If three participants skipped the item, the mean is over 17 values, not 20 — and 3.43 may be perfectly achievable. Papers frequently report a study-level N while individual measures have their own.

The subtle part: scales that average items

This trips up a lot of people. If each participant’s score is itself the average of five Likert items, then their individual score is a multiple of 1/5, and the mean across 10 participants is a multiple of 1 / (10 × 5) = 1/50 = 0.02.

The granularity is 1 / (N × items), not 1 / N. Ignore the items and you will flag means that are entirely legitimate. This is the most common way naive GRIM implementations generate false positives.

Rounding is where implementations go wrong

A subtlety that separates a careful implementation from a careless one: you cannot simply compare the reported mean to the nearest achievable value. You must ask whether any achievable value rounds to what was printed.

And rounding conventions differ. 2.345 becomes 2.35 under round-half-up and 2.34 under round-half-even (banker’s rounding, which is what most software actually does by default). An implementation that assumes one convention will eventually accuse an honest author of the impossible.

The defensible rule is to accept a value if it rounds correctly under any reasonable convention. Statlint does this, and handles every reported number as an exact decimal rather than a floating-point value — because float("2.50") silently discards the fact that the author reported two decimal places, which is the very information GRIM depends on.

What a GRIM failure means

Almost never fraud.

In practice the ranking is: a typo in the mean, a misreported or ambiguous sample size, unreported missing data, a transcription error between analysis and manuscript — and only then, rarely, fabrication. The test proves that something is wrong with the reported numbers. It says nothing whatsoever about intent.

The right response to a GRIM inconsistency is a polite question to the authors, not an accusation. Most of the time the answer is mundane and the correction is small. That is still valuable: the published record ends up more accurate than it was.

Its natural companion

GRIM only examines the mean. Its extension, GRIMMER, applies the same reasoning to the standard deviation — the sum of squares of integers must itself be an integer, and it must share the parity of the sum. Together they catch substantially more than either alone, and both run in milliseconds.

You can run GRIM, GRIMMER and five other forensic checks on a paper with Statlint — paste a results table or upload the PDF, and every impossible number comes back with the arithmetic that proves it.

Run all seven checks on a real paper

Statlint runs statcheck, GRIM, GRIMMER, SPRITE bounds, descriptive recomputation, digit analysis and the Carlisle baseline test in a single pass — free, no signup.

Analyze a paper