Chebyshev's Theorem Calculator
Apply Chebyshev's theorem, also called Chebyshev's inequality, to any data set or distribution. Enter k to get the minimum share of values within k standard deviations of the mean, enter a share to get the k that guarantees it, or enter the mean, the standard deviation and two limits to get the share guaranteed within an interval. Add the mean and standard deviation for the interval, and the number of values for how many are guaranteed.
If your data are normally distributed, the empirical rule calculator gives the exact 68-95-99.7 shares, which are far larger than Chebyshev's guarantee. To get the mean and standard deviation of your data first, use the standard deviation calculator. Every number is read as an exact decimal, so the fractions and the counts are exact.
How far from the mean; the theorem says something for k above 1
Adds how many of the n values are guaranteed
The centre of the values; adds the interval μ ± kσ
Sample or population, greater than 0; adds the interval μ ± kσ
Related Calculators
Empirical Rule Calculator
Apply the 68-95-99.7 rule to get one, two, and three standard deviation ranges.
Standard Deviation Calculator
Calculate standard deviation, variance, and spread with clear statistical outputs.
Z-Score Calculator
Convert values to z-scores and estimate probability within a normal model.
What Chebyshev's theorem says
Chebyshev's theorem, also written Chebychev or Tchebysheff and known as Chebyshev's inequality or the Bienaymé-Chebyshev inequality, is a guarantee about how spread out the values of a data set or a probability distribution can be. For any k greater than 1, at least 1 − 1/k² of the values lie within k standard deviations of the mean. It needs only the mean and the standard deviation, not the shape of the distribution, so it holds for skewed, bimodal and unknown distributions alike.
Said the other way round, at most 1/k² of the values are k or more standard deviations from the mean. For k = 2 at least 75% of the values lie within two standard deviations of the mean, and for k = 3 at least 88.89% (8/9) lie within three. Irénée-Jules Bienaymé proved it in 1853 and Pafnuty Chebyshev more generally in 1867.
Formulas
At least 1 − 1/k² of the values lie within k standard deviations of the mean (k > 1)
P(|X − μ| ≥ kσ) ≤ 1/k²
k = 1 / √(1 − p) for a share p that must lie within k standard deviations
Interval: from μ − kσ to μ + kσ
k = distance from the mean to the nearer limit / σ
At most floor(n / k²) of n values are k or more standard deviations from the mean
One tail (Cantelli): P(X − μ ≥ kσ) ≤ 1/(1 + k²)
For k of 1 or less the bound is useless: 1 − 1/k² is 0 or negative, and all of the values could lie k or more standard deviations from the mean. The calculator says so instead of returning a negative share.
How to use the calculator
| What to find | You enter | You get |
|---|---|---|
| Share within k standard deviations | k, and optionally the mean, the standard deviation and the number of values n | The minimum share within k standard deviations, the maximum outside, the maximum in one tail, the normal-distribution share for comparison, the interval μ ± kσ, and how many of the n values are guaranteed |
| Standard deviations needed for a share | The share as a percentage, and optionally the mean and the standard deviation | The k that guarantees the share, the interval μ ± kσ and the same comparisons |
| Share within an interval | The mean, the standard deviation, the lower and the upper limit, and optionally n | The k of the nearer limit, the minimum share within the interval and the maximum outside it |
Choose Load example to fill in a worked example for the mode you picked. The steps under the results show every substitution, so you can copy them into a solution.
Chebyshev's theorem versus the empirical rule
The empirical rule (68-95-99.7) gives the shares of a normal distribution. Chebyshev's theorem gives the shares every distribution must have at least, so it is much smaller, and it is the only one of the two you can use when the distribution is skewed or unknown.
| k | Chebyshev: at least within | Chebyshev: at most outside | Normal: within | Normal: outside |
|---|---|---|---|---|
| 1 | 0% | 100% | 68.27% | 31.73% |
| 1.5 | 55.56% | 44.44% | 86.64% | 13.36% |
| 2 | 75% | 25% | 95.45% | 4.55% |
| 2.5 | 84% | 16% | 98.76% | 1.24% |
| 3 | 88.89% | 11.11% | 99.73% | 0.27% |
| 4 | 93.75% | 6.25% | 99.99% | 0.0063% |
| 5 | 96% | 4% | 99.9999% | 0.000057% |
Learn how the normal shares arise in the empirical rule article, and use the normal distribution calculator for any other probability of a normal variable.
Worked example: exam scores between 77 and 95
The scores of a class have mean 86 and standard deviation 3, and their distribution is unknown. What share of the scores is guaranteed to lie between 77 and 95? Choose Share within an interval and Load example.
- The distances from the mean are 86 − 77 = 9 and 95 − 86 = 9, so both limits are 9 / 3 = 3 standard deviations away: k = 3.
- The share outside is at most 1/k² = 1/9 and the share within at least 1 − 1/9 = 8/9.
- At least 88.89% of the scores lie between 77 and 95, and at most 11.11% are below 77 or above 95.
Worked example: an interval that holds 90% of the values
Values have mean 100 and standard deviation 15. Which interval around the mean holds at least 90% of them? Choose Standard deviations needed for a share and load the example.
- k = 1 / √(1 − 0.9) = 1 / √0.1 = √10 = 3.1623.
- The interval is 100 ± √10 × 15 = 100 ± 47.4342, from 52.5658 to 147.4342.
- A normal distribution needs only 1.6449 standard deviations for 90%: an interval of about 100 ± 24.67, from 75.33 to 124.67. The wider Chebyshev interval is the price of assuming nothing about the shape.
Worked example: how many of 200 values
A sample of 200 measurements has mean 100 and standard deviation 10. How many are guaranteed to lie between 75 and 125? Choose Share within k standard deviations, enter k = 2.5, the mean, the standard deviation and n = 200.
- k = 2.5, so k² = 6.25, and 1 − 1/6.25 = 1 − 4/25 = 21/25 = 84%.
- At most floor(200 / 6.25) = 32 measurements lie 2.5 or more standard deviations from the mean, so at least 200 − 32 = 168 lie between 75 and 125.
Counts are whole numbers, so the number outside is rounded down. The calculator does this division exactly: in double precision, 121 values and k = 1.1 give 121 / 1.2100000000000002 = 99.99999999999999, which rounds down to 99 values outside when 100 are possible.
The one-sided version (Cantelli's inequality)
Chebyshev's bound covers both tails together. To bound one tail, Cantelli's inequality says that at most 1/(1 + k²) of the values are k or more standard deviations above the mean, and at most as many are below it. For k = 2 that is at most 20% above and at most 20% below, and it cannot be improved for a general distribution.
Half of the two-sided bound, 12.5% for k = 2, is only right when the distribution is symmetric. For a skewed distribution one tail can hold more than half of the 25%, which is why the one-sided bound is larger.
When Chebyshev's theorem is the right tool
- The distribution is unknown or not normal. Skewed incomes, waiting times and other data with heavy tails do not follow the empirical rule, but the theorem still holds.
- You need a guarantee, not an estimate. Quality control limits, risk bounds and proofs, such as the proof of the weak law of large numbers, use the inequality because it never fails.
- Only the mean and the standard deviation are known. No other information about the data is needed.
The guarantee is conservative. Real data usually have far more values within k standard deviations than the minimum, and the bound is attained only by a three-value distribution with the values −kσ, 0 and kσ (with probabilities 1/(2k²), 1 − 1/k² and 1/(2k²)), which real data rarely resemble.
Population or sample data
For a data set, use its own mean and standard deviation. With the population standard deviation (divisor n) at most n/k² of the values are k or more standard deviations from the mean. The sample standard deviation (divisor n − 1) is a little larger, so an interval built with it holds even more of the values and the guarantee still stands. To bound a new observation when only sample statistics are known, finite-sample versions of the inequality by Saw, Yang and Mo exist; this calculator does not cover them.
Assumptions and pitfalls
- k must be greater than 1. For k = 1 the guarantee is 0%, and for k below 1 the formula would give a negative share.
- The result is a minimum. "At least 75%" does not mean 75%; the true share is usually much larger.
- The standard deviation must be positive and finite. A distribution without a finite variance, such as the Cauchy distribution, has no Chebyshev bound.
- An interval that is not centred on the mean uses its nearer limit. The calculator applies the theorem to the largest interval around the mean that fits inside yours, so the guarantee is correct but not the best possible for a lopsided interval. If the mean is not between the limits there is no guarantee.
- Use the standard deviation of the same values as the mean. Mixing a mean from one sample and a standard deviation from another gives a meaningless guarantee.
Chebyshev's theorem in other software
| Tool | Command |
|---|---|
| Excel / Google Sheets | =1-1/B1^2 for the minimum share within k = B1 standard deviations; =1/SQRT(1-B2) for the k that guarantees the share B2 (0.9 for 90%) |
| Python | 1 - 1/k**2 for the share; 1/math.sqrt(1 - p) for k; the interval is mean - k*sd, mean + k*sd |
| R | 1 - 1/k^2 for the share; 1/sqrt(1 - p) for k |
Frequently Asked Questions
What is Chebyshev's theorem?
Chebyshev's theorem (Chebyshev's inequality) states that for any data set or distribution with a finite standard deviation, at least 1 - 1/k^2 of the values lie within k standard deviations of the mean, for any k greater than 1. It holds whatever the shape of the distribution: for k = 2 at least 75% of the values are within two standard deviations, for k = 3 at least 88.89%.
What is the formula for Chebyshev's theorem?
The proportion of values within k standard deviations of the mean is at least 1 - 1/k^2, and the proportion at least k standard deviations away is at most 1/k^2. Written for a random variable X with mean mu and standard deviation sigma: P(|X - mu| >= k sigma) <= 1/k^2. It follows from Markov's inequality applied to (X - mu)^2.
How do I find the percentage within 2 or 3 standard deviations?
Put k into 1 - 1/k^2. For k = 2 that is 1 - 1/4 = 0.75, so at least 75% of the values lie within two standard deviations of the mean. For k = 3 it is 1 - 1/9 = 8/9, at least 88.89%. For k = 1.5 it is 1 - 1/2.25 = 5/9, at least 55.56%.
How do I find k for a given percentage?
Solve 1 - 1/k^2 = p for k, which gives k = 1 / sqrt(1 - p), where p is the share as a decimal. For 75% k = 2, for 84% k = 2.5, for 90% k = sqrt(10) = 3.1623, for 95% k = sqrt(20) = 4.4721 and for 99% k = 10. The interval is then the mean plus and minus k standard deviations.
Why must k be greater than 1?
For k = 1 the formula gives 1 - 1/1 = 0, and for k below 1 it gives a negative number, so the theorem guarantees nothing: all of the values could be one or more standard deviations from the mean. The calculator reports 0% for k of 1 or less instead of a negative share.
What is the difference between Chebyshev's theorem and the empirical rule?
The empirical rule says that about 68%, 95% and 99.7% of the values of a normal distribution lie within one, two and three standard deviations. Chebyshev's theorem holds for every distribution but guarantees only at least 0%, 75% and 88.89% for k = 1, 2 and 3. Use the empirical rule when the data are normal and Chebyshev's theorem when they are not or you do not know.
Is 1 - 1/k^2 the exact percentage within k standard deviations?
No, it is a minimum. The actual share is usually much larger, and for a normal distribution it is 95.45% within two standard deviations instead of 75%. The bound is attained only by a distribution with the values -k sigma, 0 and k sigma, with probabilities 1/(2k^2), 1 - 1/k^2 and 1/(2k^2), so no better bound is possible without more information.
Does Chebyshev's theorem work for a sample?
Yes. For a data set with n values, at most n/k^2 of them are k or more standard deviations from the mean when the population standard deviation (divisor n) is used, so at most floor(n/k^2) values are outside and at least n minus that many are inside. The sample standard deviation (divisor n - 1) is slightly larger, so the guarantee still holds with it.
How do I use Chebyshev's theorem with an interval that is not centred on the mean?
Take the distance from the mean to the nearer limit, divide it by the standard deviation to get k, and apply 1 - 1/k^2. That interval around the mean fits inside yours, so at least that share of the values lies between your limits. If the mean is not between the limits, the theorem guarantees nothing.
What is the one-sided Chebyshev inequality?
Cantelli's inequality bounds one tail: P(X - mu >= k sigma) <= 1/(1 + k^2), and the same for the lower tail. For k = 2 at most 20% of the values are two or more standard deviations above the mean. It is larger than half of the two-sided bound because the distribution may be skewed, and it cannot be improved.
Embed This Calculator
Add this free calculator to your course page or LMS.
Adjust the height value to fit your page.