In 1999 a spacecraft sent to orbit Mars approached the planet too low and was destroyed. The investigation found that one team had supplied a set of thrust figures in pound-force seconds and another had read them as newton seconds. Both teams' software worked correctly. The numbers passing between them meant different things.
In 2020 nearly 16,000 positive coronavirus test results in England went unreported for several days, and the contacts of those people were not traced in time. The results had been passed between systems in an old spreadsheet format with a limit on the number of rows. Rows beyond the limit were silently dropped.
In 2012 a London trading desk lost several billion dollars. An inquiry found, among other problems, that a risk model had been operated by copying figures by hand between spreadsheets, and that one formula divided by a sum where it should have divided by an average.
None of these was a failure of statistics or of algorithms. In each case the data was at fault, and nobody saw the fault until afterwards.
The following six checks take perhaps an hour for a typical dataset. Practitioners call them data quality dimensions. The questions are plainer than the name suggests.
1. Completeness: is anything missing?
How many rows should there be? Compare the count with an independent figure: the number of orders in the finance system, the number of days in the period, last month's total. A file that should hold a year and holds eleven months looks, at a glance, exactly like a full one.
Which fields are empty, and how often? Count the blanks in every column.
What does a blank mean? This is the important question. An empty field may mean zero, or not applicable, or unknown, or not yet entered. Treated as zero, missing values drag an average down. Dropped, they may remove a whole category of cases.
Is the absence random? Usually it is not. Income is left blank more often by the rich and the poor than by those in the middle. Follow-up measurements are missing for the patients who stopped attending. If the missing rows differ from the present ones, every summary of the present ones is biased.
Are missing values in disguise? Systems often require a value, and people supply one. Look for suspicious peaks: a date of birth of 1 January 1900, a postcode of 00000, an age of 99, a weight of 0, the text "N/A" or "TBC" or a single full stop.
2. Uniqueness: is anything counted twice?
Duplicates arise when files are merged, when a process is run twice, when a customer registers again with a slightly different spelling, or when a join between two tables matches more rows than intended.
That last one is the most dangerous. Joining a table of orders to a table of customers in which a few customers appear twice will quietly duplicate those customers' orders. Revenue rises, and nothing reports an error.
Check that whatever should identify a row uniquely does so. Count the rows before and after every join. If the count changes unexpectedly, stop.
Near-duplicates are harder: "J. Okafor Ltd", "J Okafor Limited", "Okafor, J". Matching these needs judgement, and the rules chosen should be recorded.
3. Validity: are the values possible?
Each field has a set of values it can legitimately take.
- Ranges. A human age of 140, a negative quantity sold, a percentage of 250, a delivery date before the order date.
- Formats. Dates most of all. Is 03/04/2025 the third of April or the fourth of March? A file that mixes the two conventions will be read without complaint, and about half of the ambiguous dates will be wrong.
- Categories. A country field containing "UK", "U.K.", "United Kingdom", "Great Britain" and "England" holds five values for one thing.
- Types. Numbers stored as text sort wrongly and are left out of sums. Identifiers stored as numbers lose their leading zeros.
Spreadsheet software alters data on import in well-known ways. Long numbers are rounded. Text that resembles a date is converted to one. A survey of published genetics papers found that about a fifth of those with supplementary gene lists contained gene names that had been turned into dates. The scientific committee responsible eventually renamed the affected genes.
The quickest test of validity is to look at the minimum, the maximum and the list of distinct values for every column. It takes minutes and catches a great deal.
4. Consistency: does it agree with itself and with other sources?
Within a row. Does the total equal the sum of the parts? Does quantity times price equal the amount? Is the end date after the start date?
Across time. Plot the count of records per day or month. A sudden step almost always marks a change in how the data was collected: a new system, a new definition, a new form. The data before and after the step may not be comparable, and an analysis that spans it will find a "trend" that is an artefact.
Across sources. Does the sales total match the finance figure? Two systems that should agree and do not are showing you a difference of definition. Finding it early saves an awkward meeting later.
Units and definitions. The Mars spacecraft belongs here. Is revenue net or gross of tax? In which currency? Does "customer" mean an account, a person or a household? Is a weight in kilograms or pounds? If two sources have been combined, were their definitions the same?
5. Timeliness: how old is it, and as of when?
When was it extracted? Data about a period that has only just ended is often incomplete. Late-arriving transactions, returns and corrections continue to come in. The most recent days of nearly any operational dataset are undercounted, which produces a familiar chart in which everything appears to fall off at the right-hand edge.
Which date is the date? Order date, dispatch date, invoice date and payment date give four different monthly series.
Has history been rewritten? Some systems overwrite a record when it changes. A customer's current region is stored, and the region they were in when they bought is lost. An analysis of past sales by region is then really an analysis by present region.
Which time zone? Data from several countries, cut at midnight, may be cut at different midnights.
6. Accuracy: does it match reality?
This is the hardest check, because the data cannot tell you. It can only be established by comparing with the world.
Take a small random sample, perhaps thirty records, and verify each against the original source: the paper form, the physical stock, the recording of the call, the customer. It is tedious and it reveals things nothing else does. A typical finding is that a field everyone assumed reliable is filled in with a default value four times in five.
It also helps to talk to the people who enter the data. They know which fields are taken seriously and which are filled with whatever lets the screen proceed. They know that the "reason for cancellation" list has one option at the top which everybody picks.
Recording what you found
The output of the six checks should be a short written note, kept with the analysis:
- where the data came from and when it was extracted
- how many rows, and what that was checked against
- what was missing, and how it was handled
- what was removed or corrected, and why
- which definitions were assumed
- what remains uncertain
This protects the analyst, and it serves the reader. A chart that comes with the sentence "excludes 7 per cent of orders with no region recorded" is more trustworthy than one that comes with nothing.
Why this is where the time goes
People who work with data commonly estimate that preparation takes most of their time, with figures of 60 to 80 per cent often quoted. The numbers come from surveys of uneven quality, but few practitioners dispute the general picture.
That is sometimes described as waste. It is better understood as the work. The six checks are how an analyst comes to understand what a dataset really records, which may differ from what its column headings say.
Automated tools help. Software can profile a dataset, test rules each time new data arrives and raise an alarm when a distribution shifts. Language models are useful for proposing checks and for writing the code. None of them knows that the "delivery date" column changed its meaning in March. Somebody has to find that out.
A last example
An analyst at a retailer was asked why average basket value had fallen eight per cent in a month. She spent two days on customer segments before plotting the daily count of transactions. It had risen sharply on the fourth. A till update on that date had started recording each use of a carrier-bag charge as a separate transaction.
Nothing about the customers had changed. The fall was produced by a change in what counted as a transaction, and checks two and four would have found it in ten minutes.



