Data Quality
Assessment
Learn to identify and evaluate missingness, outliers, duplicates, and bias in datasets: the four pillars of trustworthy analysis.
What Is Data Quality?
Data quality measures how well a dataset serves the purpose of the analysis it supports. High-quality data is accurate, complete, consistent, and unbiased. Poor data quality leads to flawed conclusions, costing businesses billions of dollars every year.
The Four Pillars of Data Quality Issues
Why Data Quality Matters
Understanding Missingness
Missing data occurs when expected values are absent. We classify missingness into three types based on the mechanism that caused the data to be missing:
Detecting Outliers
An outlier is a data point that lies significantly outside the typical range. The IQR method defines outliers as values below \( Q_1 - 1.5 \cdot \text{IQR} \) or above \( Q_3 + 1.5 \cdot \text{IQR} \), where \( \text{IQR} = Q_3 - Q_1 \).
The Z-Score Method
For normally distributed data, the Z-score measures how many standard deviations a value is from the mean. A common rule flags values with \( |z| > 3 \) as outliers:
Identifying Duplicates
Duplicate records appear when data is merged from multiple sources, entered manually more than once, or copied during ETL processes. They inflate counts and distort metrics like averages, totals, and proportions.
Recognizing Bias in Data
Bias is a systematic error that makes the data unrepresentative of the population it claims to describe. Unlike random error, bias does not cancel out with more data.
Missing vs Biased Data
| Missing Data | Biased Data | |
|---|---|---|
| What it is | Values are absent (null, blank) | Values are present but skewed |
| Visibility | Easy to detect programmatically | Hard to detect without domain knowledge |
| Impact on mean | Depends on mechanism (MCAR / MAR / MNAR) | Systematically shifts the mean |
| Fix | Imputation, deletion, or collection | Re-sampling, weighting, or redesign |
| More data helps? | Yes (reduces uncertainty) | No (bias persists at scale) |
The Data Quality Framework
How to Assess Data Quality
Example: Checking Missingness
A customer survey dataset has 500 rows. You count null values per column:
Example: Outlier Calculation
Monthly sales data (in thousands): 12, 15, 14, 13, 16, 15, 14, 95. Is \( 95 \) an outlier?
Example: Spotting Bias
A company surveys employee satisfaction using an online-only form. Here is the response breakdown compared to the actual workforce:
| Department | Workforce % | Survey % | Gap |
|---|---|---|---|
| Office Staff | 40% | 72% | +32% |
| Warehouse | 35% | 14% | -21% |
| Field Sales | 25% | 14% | -11% |
Common Mistakes
Summary: Data Quality at a Glance
| Issue | Detection | Remediation | Risk If Ignored |
|---|---|---|---|
| Missingness | Null counts, % missing | Impute, collect, or drop | Reduced sample size, bias |
| Outliers | IQR fence, Z-score | Investigate, cap, or remove | Skewed mean, bad models |
| Duplicates | Exact and fuzzy matching | Deduplicate, merge records | Inflated counts, wrong totals |
| Bias | Demographic comparison | Re-sample, weight, redesign | Systematic error at scale |
Question 1 of 5
A dataset column has \( 22\% \) of its values missing. These missing values all come from respondents who declined to report their income. What type of missingness is this most likely?
Question 2 of 5
Given the sorted dataset \( 5, 7, 8, 9, 11, 13, 40 \), with \( Q_1 = 7 \) and \( Q_3 = 13 \), which value is flagged as an outlier using the IQR method?
Question 3 of 5
A retail company merges data from its website and in-store systems. After merging, the total customer count jumps from 10,000 to 14,200. Which data quality issue is the most likely cause?
Question 4 of 5
A study on average household income surveys people at a shopping mall during weekday business hours. The resulting mean income is higher than the census figure. Which type of bias is most responsible?
Question 5 of 5
Which statement about data quality is FALSE?