Markov and Chebyshev Inequalities

Markov’s inequality says that for a nonnegative random variable X and any a > 0, P(X ≥ a) ≤ E(X)/a. Chebyshev’s inequality says that for any random variable with mean μ and standard deviation σ, P(|X − μ| ≥ kσ) ≤ 1/k² for every k > 0. Both give guaranteed bounds even when the distribution is unknown.

Before this lesson: Expected Value of a Continuous Random Variable, Standard Deviation and Absolute Value Inequalities

Bounds from the mean and the variance

Suppose the average wait at a clinic is 10 minutes. Could half of all patients wait 30 minutes or more? No: those patients alone would push the average to at least 15 minutes. Waits cannot be negative, so the mean limits how much probability can sit far out in the right tail.

That is Markov’s inequality. Chebyshev’s inequality applies the same idea to the squared distance from the mean, (X − μ)². A small variance means values cannot stray far from μ very often.

Neither inequality needs the shape of the distribution. The price is that the bounds are often loose: the true probability is usually much smaller than the bound.

Markov and Chebyshev inequality formulas

Markov’s inequality

If X ≥ 0 and a > 0, then

P(X \ge a) \le \dfrac{E(X)}{a}

Chebyshev’s inequality

If X has mean μ and finite variance σ², then for any c > 0 and any k > 0,

P(|X - \mu| \ge c) \le \dfrac{\sigma^2}{c^2} \qquad \text{and} \qquad P(|X - \mu| \ge k\sigma) \le \dfrac{1}{k^2}

Taking complements gives the “within” form: P(|X − μ| < kσ) ≥ 1 − 1/k². At least 75% of any distribution lies within 2 standard deviations of the mean, and at least 88.9% lies within 3.

Bar chart comparing Chebyshev's guaranteed minimum probability within k standard deviations of the mean with the exact normal probability, for k = 1.5, 2, 2.5 and 3. Chebyshev values in navy are 0.556, 0.750, 0.840 and 0.889. Normal values in light blue are 0.866, 0.954, 0.988 and 0.997.
Chebyshev’s bound holds for every distribution, so it is lower than the exact probability for a normal distribution at each k.

Why the inequalities are true

For a continuous X ≥ 0 with density f, the proof of Markov’s inequality takes three steps.

E(X) = \int_0^{\infty} x f(x)\,dx \ge \int_a^{\infty} x f(x)\,dx

Drop the part of the integral from 0 to a, which is nonnegative.

\int_a^{\infty} x f(x)\,dx \ge \int_a^{\infty} a f(x)\,dx

On [a, ∞), x ≥ a.

\int_a^{\infty} a f(x)\,dx = a\,P(X \ge a)

Pull out a; the integral of f from a to ∞ is P(X ≥ a).

E(X) \ge a\,P(X \ge a) \implies P(X \ge a) \le \dfrac{E(X)}{a}

Combine the steps and divide by a > 0.

For Chebyshev’s inequality, let Y = (X − μ)². Y is nonnegative with E(Y) = σ², and |X − μ| ≥ c exactly when Y ≥ c². Markov’s inequality gives P(Y ≥ c²) ≤ σ²/c². Setting c = kσ gives the 1/k² form.

Markov and Chebyshev inequality examples

Example 1: Clinic wait times (word problem)

Waiting times at a clinic have mean 12 minutes. Nothing else is known about the distribution. Find an upper bound for the probability that a patient waits 30 minutes or more.

X \ge 0, \quad E(X) = 12, \quad a = 30

Waiting times are nonnegative, so Markov’s inequality applies.

P(X \ge 30) \le \dfrac{12}{30}

Markov’s inequality.

P(X \ge 30) \le 0.4

Divide.

Answer: at most 0.4, so at most 40% of patients wait 30 minutes or more.

Example 2: How loose is the bound?

Suppose the waits in Example 1 are in fact exponential with mean 12. Find the exact probability P(X ≥ 30) and compare it with the bound 0.4.

\lambda = \dfrac{1}{12}

The rate is 1 over the mean (see exponential distribution).

P(X \ge 30) = e^{-30/12}

Exponential tail: P(X ≥ a) = e^(−λa).

P(X \ge 30) = e^{-2.5} \approx 0.0821

30/12 = 2.5.

Answer: the exact probability is about 0.0821, about one fifth of the bound. Markov’s bound is safe for every distribution, so it cannot be tight for this one.

Example 3: Exam scores (word problem)

Scores on a final exam have mean 72 and standard deviation 8. The shape of the distribution is unknown. Find a lower bound for the probability that a score is between 56 and 88.

72 - 56 = 16 \quad \text{and} \quad 88 - 72 = 16

The interval is centered at the mean, 16 points each way.

k = \dfrac{16}{8} = 2

16 points is 2 standard deviations.

P(|X - 72| \lt 16) \ge 1 - \dfrac{1}{2^2}

Chebyshev, “within” form.

P(|X - 72| \lt 16) \ge 1 - \dfrac{1}{4} = 0.75

Simplify.

Answer: at least 0.75. The true value may be higher, but no distribution with this mean and SD can have less than 75% of scores in this range. Here “between” means 56 < X < 88, which is the event |X − 72| < 16.

Example 4: A bound and a guaranteed interval

X has mean 50 and variance 25. (a) Bound P(|X − 50| ≥ 12). (b) Find an interval centered at 50 that contains X with probability at least 0.96.

P(|X - 50| \ge 12) \le \dfrac{25}{12^2}

(a) Chebyshev with σ² = 25 and c = 12.

P(|X - 50| \ge 12) \le \dfrac{25}{144} \approx 0.174

12² = 144.

1 - \dfrac{1}{k^2} = 0.96

(b) Set the “within” bound equal to 0.96.

\dfrac{1}{k^2} = 0.04 \implies k^2 = 25 \implies k = 5

Solve for k, taking the positive root.

k\sigma = 5 \cdot 5 = 25

σ = √25 = 5.

50 - 25 = 25, \quad 50 + 25 = 75

Go 25 each way from the mean.

Answer: (a) at most 25/144 ≈ 0.174; (b) the interval (25, 75) contains X with probability at least 0.96.

Example 5: How many people to survey? (word problem)

A pollster estimates a proportion p with the sample proportion X̄ of n independent yes/no answers (1 for yes, 0 for no). How large must n be so that Chebyshev guarantees P(|X̄ − p| ≥ 0.05) ≤ 0.1, whatever p is?

\operatorname{Var}(\bar{X}) = \dfrac{p(1 - p)}{n}

Each answer has variance p(1 − p); the sample mean divides it by n.

p(1 - p) \le \dfrac{1}{4} \implies \operatorname{Var}(\bar{X}) \le \dfrac{1}{4n}

p(1 − p) is largest at p = 1/2 (see vertex of a parabola).

P(|\bar{X} - p| \ge 0.05) \le \dfrac{1/(4n)}{0.05^2}

Chebyshev with c = 0.05; E(X̄) = p.

\dfrac{1/(4n)}{0.0025} = \dfrac{1}{0.01n} = \dfrac{100}{n}

4 × 0.0025 = 0.01.

\dfrac{100}{n} \le 0.1 \implies n \ge 1000

Require the bound to be at most 0.1, then solve.

Answer: n = 1000 answers are enough for any p. Because the bound shrinks like 1/n, a large sample makes the estimate close to p with high probability. That is the idea behind the next lesson.

Common mistakes

MistakeExample of the errorFix
Using Markov for a variable that can be negativeBounding P(X ≥ 5) for a temperature with mean 2°CMarkov needs X ≥ 0; use Chebyshev or shift X first.
Using σ instead of σ²P(|X − 50| ≥ 12) ≤ 5/144The numerator is the variance: 25/144.
Treating the bound as the probability“P(X ≥ 30) = 0.4” in Example 1The inequality only gives an upper limit: P(X ≥ 30) ≤ 0.4.
Mixing up “outside” and “within”Saying at least 1/4 is within 2σOutside: at most 1/k². Within: at least 1 − 1/k².
Using k ≤ 1Bound 1/k² = 4 for k = 0.5For k ≤ 1 the bound is at least 1 and tells you nothing.
Using the normal 95% for any distributionAt least 95% within 2σ of an unknown distributionWithout normality, only 75% is guaranteed.

Related ideas

The empirical rule

For a normal distribution, the empirical rule gives about 68%, 95% and 99.7% within 1, 2 and 3 standard deviations. Chebyshev’s guarantees (0%, 75%, 88.9%) are weaker because they hold for any distribution shape, not only the normal.

The bounds can be exact

Chebyshev’s bound cannot be improved in general. If X equals −1 and 1 with probability 1/8 each and 0 otherwise, then σ = 1/2 and P(|X| ≥ 2σ) = 1/4 = 1/2², exactly the bound.

Sharper bounds from MGFs

Applying Markov’s inequality to e^(tX) instead of X gives Chernoff bounds, which use the moment generating function and shrink much faster in the tails.

Practice problems

  1. X ≥ 0 and E(X) = 4. Find an upper bound for P(X ≥ 10).
  2. A website gets an average of 2,000 visits a day. Find an upper bound for the probability that it gets 8,000 or more visits on a given day.
  3. X ≥ 0 and E(X) = 6. Find the smallest a for which Markov’s inequality guarantees P(X ≥ a) ≤ 0.05.
  4. X has mean 100 and standard deviation 15. Find a lower bound for P(70 < X < 130).
  5. X has mean 100 and standard deviation 15. Find an upper bound for P(|X − 100| ≥ 45).
  6. X has mean 20 and variance 16. Find an upper bound for P(|X − 20| ≥ 10).
  7. X has mean 20 and standard deviation 4. Find an interval centered at the mean that contains X with probability at least 0.84.
  8. X is exponential with rate 1, so E(X) = 1 and Var(X) = 1. Find the Markov bound and the Chebyshev bound for P(X ≥ 3), and the exact value.
  9. X is the roll of a fair die, with mean 3.5 and variance 35/12. Find the Chebyshev bound for P(|X − 3.5| ≥ 2.5) and the exact probability.
  10. Each X_i has variance 9, and the X_i are independent. How large must n be so that Chebyshev guarantees P(|X̄ − μ| ≥ 1) ≤ 0.05?
Show answers

1.

P(X \ge 10) \le \dfrac{4}{10} = 0.4

Markov’s inequality with a = 10.

Answer: at most 0.4

2.

P(X \ge 8000) \le \dfrac{2000}{8000} = 0.25

Visits are nonnegative, so use Markov’s inequality.

Answer: at most 0.25

3.

\dfrac{6}{a} = 0.05

Set the Markov bound equal to 0.05.

a = \dfrac{6}{0.05} = 120

Solve for a.

Answer: a = 120

4.

k = \dfrac{130 - 100}{15} = 2

The interval is 30 points, or 2 SDs, each way.

P(|X - 100| \lt 30) \ge 1 - \dfrac{1}{4} = 0.75

Chebyshev, “within” form.

Answer: at least 0.75

5.

k = \dfrac{45}{15} = 3

45 points is 3 SDs.

P(|X - 100| \ge 45) \le \dfrac{1}{9} \approx 0.111

Chebyshev with k = 3.

Answer: at most 1/9 ≈ 0.111

6.

P(|X - 20| \ge 10) \le \dfrac{16}{10^2} = 0.16

Chebyshev with σ² = 16 and c = 10.

Answer: at most 0.16

7.

1 - \dfrac{1}{k^2} = 0.84 \implies k^2 = \dfrac{1}{0.16} = 6.25

Set the “within” bound to 0.84 and solve.

k = 2.5, \quad k\sigma = 2.5 \cdot 4 = 10

Take the positive root and multiply by σ.

Answer: (10, 30)

8.

P(X \ge 3) \le \dfrac{1}{3} \approx 0.333

Markov with E(X) = 1.

P(X \ge 3) \le P(|X - 1| \ge 2) \le \dfrac{1}{2^2} = 0.25

X ≥ 3 means X − 1 ≥ 2; Chebyshev with c = 2.

P(X \ge 3) = e^{-3} \approx 0.0498

Exact exponential tail.

Answer: Markov 1/3, Chebyshev 0.25, exact about 0.0498

9.

P(|X - 3.5| \ge 2.5) \le \dfrac{35/12}{6.25} = \dfrac{7}{15} \approx 0.467

Chebyshev with c = 2.5, so c² = 6.25.

P(|X - 3.5| \ge 2.5) = P(X = 1 \text{ or } X = 6) = \dfrac{2}{6} = \dfrac{1}{3}

Only 1 and 6 are 2.5 or more from 3.5.

Answer: bound 7/15 ≈ 0.467; exact 1/3

10.

\operatorname{Var}(\bar{X}) = \dfrac{9}{n}

Variance of a sample mean of n independent values.

\dfrac{9/n}{1^2} \le 0.05 \implies n \ge \dfrac{9}{0.05} = 180

Chebyshev with c = 1, then solve for n.

Answer: n ≥ 180

Markov and Chebyshev inequality FAQ

What is the difference between Markov’s and Chebyshev’s inequality?

Markov’s inequality uses only the mean and needs X ≥ 0; it bounds one tail. Chebyshev’s inequality uses the mean and variance, works for any variable with finite variance, and bounds both tails at once.

What does Chebyshev’s theorem say about 2 standard deviations?

At least 1 − 1/2² = 75% of any distribution lies within 2 standard deviations of its mean, and at most 25% lies 2 or more standard deviations away.

Why are the Chebyshev and Markov bounds so loose?

They must hold for every distribution with the given mean (and variance), including extreme ones. For a particular distribution such as the normal, the true tail probabilities are usually much smaller.

When should you use Chebyshev’s inequality?

Use it when you know the mean and standard deviation but not the shape of the distribution, or when you need a guarantee, such as a sample size that works for every population.

Summary

  • Markov: for X ≥ 0 and a > 0, P(X ≥ a) ≤ E(X)/a.
  • Chebyshev: P(|X − μ| ≥ c) ≤ σ²/c², or P(|X − μ| ≥ kσ) ≤ 1/k².
  • Within k standard deviations: probability at least 1 − 1/k² (75% for k = 2, 88.9% for k = 3).
  • The bounds work for any distribution, so they are often loose; never treat them as exact probabilities.
  • Chebyshev applied to a sample mean shows that large samples give estimates close to the true mean.

Previous lesson: Moment Generating Functions

Next lesson: Law of Large Numbers

Back to the Probability Theory Index