Skip to main content
|6 min read|Analysez AI

Outliers in Biomedical Data: Detection Rules, Clinical Plausibility, and Sensitivity Analysis

While reviewing data from a kidney function study, the researcher noticed that most serum creatinine readings ranged between 0.7 and 1.4 mg/dL, except for two: the first was 110 mg/dL, and the second was 6.8 mg/dL.

Had the researcher treated both values the same way, whether by deleting both as “outliers” or by keeping both without checking, it would have been a methodological error. On checking the laboratory file, the first value (110) turned out to be a decimal point error whose true value was 1.10 mg/dL, whereas the second (6.8) was a genuine reading from a patient with acute kidney failure!

An outlier is not an error to be wiped automatically. It is a warning sign asking you to tell a data entry error apart from a real biological phenomenon.

The Two Basic Types of Outliers: Where Do They Come From?

Before applying any statistical formula, you must recognise that values far from the centre of the data fall into two categories by source, and they are handled in completely different ways:

1. Measurement, Data-Entry and Coding Errors

  • Common examples: a forgotten decimal point (writing a height of 175 metres instead of 1.75 metres, or a weight of 750 kg instead of 75.0 kg), unit mix-ups between laboratories (mmol/L versus mg/dL), or missing-value codes such as 999 or -99 left inside a numeric column, so that software counts them as real numbers.
  • The right decision: go back to the original record (source verification) and correct the number immediately, or turn it into a missing value if its origin cannot be confirmed and the value is clinically impossible.

2. True Biological or Clinical Extremes

  • Common examples: an intensive care patient whose liver enzyme level is ten times the normal range, or an exceptional patient who stayed in hospital for 45 days while everyone else stayed 4 days.
  • The right decision: a genuine observation must not be deleted merely because it is far from the mean or because it weakens the p-value the researcher hopes for. Deleting genuine extreme cases without a prior scientific justification is cherry-picking, and it distorts how well the sample represents the real clinical population.

Three Systematic Ways to Detect Outliers

1. Clinical Plausibility Ranges

This is the first line of defence before any statistics: define the physiologically possible limits of human life for each variable. For example, the body temperature of a living person cannot be 12°C or 65°C, and oxygen saturation cannot exceed 100%. Any number outside these limits is most likely an entry or measurement error.

2. Tukey’s IQR Fences (the Boxplot Rule)

This method is robust because it relies on quartiles, which are far less affected by extreme values than the mean and standard deviation:

  • Calculate the first quartile (Q₁: the 25th percentile) and the third quartile (Q₃: the 75th percentile).
  • Calculate the interquartile range (IQR = Q₃ - Q₁).
  • Lower fence: Q₁ - 1.5 × IQR.
  • Upper fence: Q₃ + 1.5 × IQR. Any value outside these two fences appears as an individual point on a boxplot and is classed as a possible outlier that needs checking. It is called an extreme outlier if it exceeds Q₃ + 3 × IQR or falls below Q₁ - 3 × IQR.

3. The Z-Score Rule

This measures how many standard deviations an observation lies from the mean:

Zᵢ = (xᵢ - x̄)/s

A threshold of |Z| > 3.0 (or |Z| > 2.5 in smaller samples) is commonly used as a signal to examine the value. But this method has a mathematical weakness to watch for: because the mean x̄ and the standard deviation s both enter the calculation of Z, a single very large outlier raises the standard deviation s itself, which can hide other extreme values (the masking effect). The IQR rule therefore remains more robust for initial detection.

A Numerical Example With the Full Calculation: Applying the IQR Rule and the Z-Score

Suppose we measured C-reactive protein (CRP, in mg/L) in eleven patients, with the readings sorted in ascending order: 2, 3, 4, 4, 5, 5, 6, 7, 8, 9, 35

First: Detection Using the IQR Rule

Number of observations n = 11:

  1. Median (Q₂): the sixth value in the ordering, (11 + 1)/2 = 6, whose value is 5 mg/L.
  2. First quartile (Q₁): taking observation number (11 + 1)/4 = 3 in the ordering, the third value is 4 mg/L.
  3. Third quartile (Q₃): observation number 3 × (11 + 1)/4 = 9 in the ordering, whose value is 8 mg/L.
  4. Calculate the interquartile range (IQR):

IQR = Q₃ - Q₁ = 8 - 4 = 4 mg/L

  1. Calculate the lower and upper fences:
    • Lower fence: Q₁ - (1.5 × 4) = 4 - 6 = -2 mg/L.
    • Upper fence: Q₃ + (1.5 × 4) = 8 + 6 = 14 mg/L.
    • Upper fence for extreme outliers (3 × IQR): 8 + (3 × 4) = 20 mg/L.

By comparison, the readings of the first ten patients all lie between 2 and 9 (entirely within the normal range), while the eleventh reading (35 mg/L) exceeds the upper fence (14) and even exceeds the extreme-outlier threshold (20).

Second: Detection Using the Z-Score on the Same Data

  • Sum of the eleven values: 2+3+4+4+5+5+6+7+8+9+35 = 88.
  • Mean (x̄): 88 / 11 = 8.0 mg/L.
  • Deviations from the mean (xᵢ - 8): (-6, -5, -4, -4, -3, -3, -2, -1, 0, +1, +27).
  • Sum of squared deviations: 36 + 25 + 16 + 16 + 9 + 9 + 4 + 1 + 0 + 1 + 729 = 846.
  • Sample variance: s² = 846 / (11 - 1) = 84.6 ⇒ standard deviation s = √(84.6) ≈ 9.20 mg/L.
  • Z-score of the reading 35:

Z = (35 - 8.0)/9.20 = 27.0/9.20 ≈ +2.93

Notice how the reading 35 alone pushed the standard deviation up from about 2.21 (for the first ten) to 9.20, so the Z value did not exceed the traditional threshold of 3.0 despite its obvious extremity! This shows in practice why it is important to check the IQR rule and the boxplot.

What to Do After Finding a Biologically Genuine Outlier

If you checked the original record and confirmed that the reading of 35 mg/L is genuine, from a patient with acute inflammation, you have three sound methodological paths instead of arbitrary deletion:

  1. Use robust or non-parametric statistical methods: express the data as median and interquartile range instead of the mean, and use rank-based tests (such as Mann–Whitney U or Wilcoxon) or robust regression, which mathematically reduces the weight of outlying observations without deleting them.

  2. Transform the variable mathematically (data transformation): for positive, right-skewed biological variables (such as cytokine concentrations or CRP), a log-transformation helps compress the long tail and brings the distribution closer to a symmetric shape.

  3. Run a sensitivity analysis: an essential practice for scientific transparency. You run the main analysis with all patients included (the full sample), then rerun the same analysis after excluding the outlier, and show the reader both results. If the result and its direction stay the same in both cases, your scientific conclusion is robust and does not depend on a single patient.

How to Write It Up in Your Research

Full transparency in documenting every decision about outliers protects your paper from any methodological challenge:

Sample reporting sentence (APA 7th edition style):

“Continuous variables were screened for outliers using boxplots, Tukey’s interquartile range fences (1.5 × IQR), and predefined clinical plausibility bounds. One transcription error was corrected against source laboratory records, whereas two biologically plausible extreme values were retained in the primary analysis. A sensitivity analysis excluding these two observations yielded consistent effect estimates and statistical significance.”

To apply this to your own data, try it on analysez.ai.

Subscribe to «نشرة أناليسيز»

One statistical concept a week, with a worked example and a sentence you can adapt for your paper.

Subscribe on LinkedIn

Need help with your statistical analysis?

Run your analysis on Analysez AI: data cleaning, descriptive and inferential statistics, and a publication-ready report.