# Binomial distribution: how likely is k?

Computes exact binomial probabilities P(X = k), P(X < k), P(X ≤ k), P(X > k), and P(X ≥ k) for n trials with success probability p, with the mean and standard deviation.

- Page: https://www.acalculator.org/statistics/binomial-distribution-calculator
- JSON spec: https://www.acalculator.org/statistics/binomial-distribution-calculator.json
- Version: 4067d6214ce3

## Default answer

Example with the default inputs (Number of trials (n) 10, Probability of success (p) 0.5, Number of successes (k) 5): With 10 trials and p = 0.5, the chance of exactly 5 successes is 0.246094, and of at most 5 is 0.623047.

## Inputs

| Key | Label | Description |
| --- | --- | --- |
| n | Number of trials (n) | How many independent trials, from 1 to 1,000. |
| p | Probability of success (p) | The chance of a success on each trial, from 0 to 1. |
| k | Number of successes (k) | The number of successes to find the probability of, from 0 to n. |

## Outputs

| Key | Label | Description |
| --- | --- | --- |
| exactly | P(X = k) | The probability of exactly k successes. |
| below | P(X < k) | The probability of fewer than k successes. |
| atMost | P(X ≤ k) | The probability of k or fewer successes. |
| above | P(X > k) | The probability of more than k successes. |
| atLeast | P(X ≥ k) | The probability of k or more successes. |
| mean | Mean (np) | The expected number of successes: n × p. |
| variance | Variance np(1 − p) | The variance of the number of successes: n × p × (1 − p). |
| sd | Standard deviation | The square root of the variance: √(n × p × (1 − p)). |

## Method

P(X = k) = C(n, k) × pᵏ × (1 − p)ⁿ⁻ᵏ; P(X ≤ k) = Σ P(X = j) for j = 0 … k; mean = np; variance = np(1 − p).

## Assumptions

- The n trials are independent, and each has the same probability p of success.
- Every probability is summed exactly from the decimal p you type, then rounded once, so tiny tails keep full precision.

## Worked examples

1. n = 10, p = 0.5, k = 5 gives exactly = 0.246094, below = 0.376953, atMost = 0.623047, above = 0.376953, mean = 5, sd = 1.581139. Source: NIST/SEMATECH e-Handbook of Statistical Methods, §1.3.6.6.18 Binomial Distribution. https://www.itl.nist.gov/div898/handbook/eda/section3/eda366i.htm.
2. n = 20, p = 0.41, k = 12 gives atMost = 0.973785, mean = 8.2, variance = 4.838, sd = 2.199545. Source: OpenStax, Introductory Statistics 2e, §4.3 Binomial Distribution. https://openstax.org/books/introductory-statistics-2e/pages/4-3-binomial-distribution, Example 4.13 (P(x ≤ 12) = 0.9738, mean 8.2, standard deviation 2.20).
3. n = 200, p = 0.015, k = 8 gives atMost = 0.996496, mean = 3. Source: OpenStax, Introductory Statistics 2e, §4.3 Binomial Distribution. https://openstax.org/books/introductory-statistics-2e/pages/4-3-binomial-distribution, Example 4.15 (P(x ≤ 8) = 0.9965, mean 3).
4. n = 1,000, p = 0.001, k = 10 gives atLeast = 0, exactly = 0. Source: NIST/SEMATECH e-Handbook of Statistical Methods, §1.3.6.6.18 Binomial Distribution. https://www.itl.nist.gov/div898/handbook/eda/section3/eda366i.htm.
5. n = 5, p = 0.1, k = 0 gives exactly = 0.59049, below = 0, atLeast = 1, above = 0.40951. Source: NIST/SEMATECH e-Handbook of Statistical Methods, §1.3.6.6.18 Binomial Distribution. https://www.itl.nist.gov/div898/handbook/eda/section3/eda366i.htm.
6. n = 4, p = 0.3, k = 7 gives exactly = 0, atMost = 1, atLeast = 0. Source: NIST/SEMATECH e-Handbook of Statistical Methods, §1.3.6.6.18 Binomial Distribution. https://www.itl.nist.gov/div898/handbook/eda/section3/eda366i.htm.

## FAQ

### What is a binomial distribution?

It counts the successes in a fixed number n of independent trials, when each trial has the same chance p of success, such as heads in 10 coin tosses or defective parts in a batch of 200. The number of successes X can be any whole number from 0 to n.

### How do I calculate a binomial probability?

Use P(X = k) = C(n, k) × pᵏ × (1 − p)ⁿ⁻ᵏ, where C(n, k) = n! ÷ (k! (n − k)!) counts the ways to place k successes among n trials. For 5 heads in 10 fair tosses: C(10, 5) = 252, and 252 × 0.5¹⁰ = 252 ÷ 1024 = 0.246094.

### What is the difference between P(X ≤ k) and P(X < k)?

P(X ≤ k) includes k itself; P(X < k) stops at k − 1. They differ by exactly P(X = k). The same holds for P(X ≥ k) and P(X > k).

### How do I find the probability of at least one success?

Use P(X ≥ 1) = 1 − P(X = 0) = 1 − (1 − p)ⁿ. Enter k = 1 and read P(X ≥ 1). With p = 0.1 and 10 trials it is 1 − 0.9¹⁰ = 0.651322.

### What are the mean and standard deviation of a binomial distribution?

The mean is n × p and the standard deviation is √(n × p × (1 − p)). For 20 trials with p = 0.41, the mean is 8.2 and the standard deviation is √4.838 = 2.1995.

### When can I use the normal distribution instead?

A common rule is when both n × p and n × (1 − p) are at least 5 (some books say 10). This calculator does not need the approximation: it adds up the exact probabilities for up to 1,000 trials.

## Sources

- NIST/SEMATECH e-Handbook of Statistical Methods, §1.3.6.6.18 Binomial Distribution. https://www.itl.nist.gov/div898/handbook/eda/section3/eda366i.htm
- OpenStax, Introductory Statistics 2e, §4.3 Binomial Distribution. https://openstax.org/books/introductory-statistics-2e/pages/4-3-binomial-distribution
