Tutorials › Statistical Theory I - Probability and Distribution Theory › Exact Binomial Probability Calculations

Bernoulli and Binomial Families · Tutorial 112 of 994

Exact Binomial Probability Calculations

Calculate exact probabilities for binomial counts, translating verbal bounds carefully and using complements to simplify tails.

Beginner 9 min read

What You'll Learn

  • Evaluate a binomial point probability from its mass function.
  • Add the relevant point probabilities to find an interval probability.
  • Translate strict and inclusive bounds into integer cutoffs correctly.
  • Calculate upper and lower tails, including by taking a complement.
  • Handle probability bounds outside the binomial support.

From a Binomial Model to an Exact Probability

A binomial model describes a count \(X\) of successes in a fixed number \(n\) of independent trials, each with success probability \(p\). Once \(n\) and \(p\) are specified, exact probabilities come from the probability mass function. The calculation is finite, but care is needed: a point probability uses one term, an interval probability adds several terms, and a strict inequality can shift the integer cutoff by one.

Here, “exact” means that the probability is calculated from the binomial model rather than approximated by another distribution. Decimal values below are finite calculations from that model. We use the support \(\{0,1,\ldots,n\}\); events requiring counts outside this set have probability zero.

Definition: If \(X\sim\operatorname{Bin}(n,p)\), where \(n\) is a nonnegative integer and \(0\leq p\leq1\), then $$ P(X=k)=\binom{n}{k}p^k(1-p)^{n-k},\qquad k=0,1,\ldots,n. $$ For integer \(k\) outside \(\{0,\ldots,n\}\), \(P(X=k)=0\). At the boundary values, the distribution is degenerate: \(P(X=0)=1\) when \(p=0\), and \(P(X=n)=1\) when \(p=1\).

For \(0<p<1\), the mass function gives a direct recipe: substitute the desired integer \(k\), calculate the binomial coefficient, and evaluate the powers of \(p\) and \(1-p\). For a range of possible counts, add the mass at every integer in the range. Writing down those integers before calculating is often the simplest way to avoid an off-by-one error.

Point Probabilities

A point probability asks for one particular count, such as exactly two successes. The binomial coefficient accounts for how many different arrangements of the successes and failures produce that count; the powers give the probability of each such arrangement.

Worked Example: Exactly Two Successes

Suppose \(X\sim\operatorname{Bin}(8,0.3)\). Find \(P(X=2)\).

Substitute \(n=8\), \(p=0.3\), and \(k=2\) into the mass function: $$ P(X=2)=\binom{8}{2}(0.3)^2(0.7)^6. $$

The binomial coefficient is \(\binom{8}{2}=8\cdot7/(2\cdot1)=28\), and \((0.7)^6=0.117649\). Therefore, $$ P(X=2)=28(0.09)(0.117649)=28(0.01058841)=0.29647548. $$

Thus the probability of exactly two successes is \(0.29647548\), or about \(0.2965\). The coefficient matters: \( (0.3)^2(0.7)^6\) is the probability of one particular arrangement with two successes, not the probability of all arrangements with two successes.

Interval Probabilities

Because a binomial variable takes integer values, an interval probability is a finite sum of point probabilities. The endpoints must be interpreted before applying the mass function. For example, \(2\leq X\leq4\) includes the three values \(2,3,4\), whereas \(2<X<4\) includes only \(3\).

Result: For integers \(a\leq b\), if \(X\sim\operatorname{Bin}(n,p)\), then $$ P(a\leq X\leq b) =\sum_{k=\max(0,a)}^{\min(n,b)} \binom{n}{k}p^k(1-p)^{n-k}, $$ where the sum is defined to be zero if its lower limit exceeds its upper limit. To see why, the events \(\{X=k\}\) for distinct integers \(k\) are disjoint, and their union over the displayed range is exactly \(\{a\leq X\leq b\}\) within the support. Additivity of probability for this finite collection of disjoint events gives the formula.

Worked Example: Probability of a Count in an Inclusive Interval

Let \(X\sim\operatorname{Bin}(10,0.2)\). Find \(P(2\leq X\leq4)\).

The inclusive bounds require the values \(2,3,4\), so calculate and add three masses: $$ \begin{aligned} P(2\leq X\leq4) &=P(X=2)+P(X=3)+P(X=4)\\ &=\binom{10}{2}(0.2)^2(0.8)^8 +\binom{10}{3}(0.2)^3(0.8)^7 +\binom{10}{4}(0.2)^4(0.8)^6. \end{aligned} $$

Evaluating each term, $$ \begin{aligned} P(X=2)&=45(0.04)(0.16777216)=0.301989888,\\ P(X=3)&=120(0.008)(0.2097152)=0.201326592,\\ P(X=4)&=210(0.0016)(0.262144)=0.088080384. \end{aligned} $$

Adding the results gives $$ P(2\leq X\leq4)=0.301989888+0.201326592+0.088080384=0.591396864. $$

The calculation includes both endpoint masses. If either endpoint were excluded, its corresponding term would need to be removed.

Strict and Inclusive Tails

A lower tail collects values at or below a cutoff; an upper tail collects values at or above a cutoff. “At or below” and “at or above” are inclusive. By contrast, “below” and “greater than” are strict. Since \(X\) is integer-valued, \(X>c\) is equivalent to \(X\geq c+1\) when \(c\) is an integer.

A tail may be calculated by summing its point masses directly. Alternatively, it may be easier to calculate the probability of the complementary event and subtract from one. The identity is a consequence of a disjoint partition: an event and its complement have probabilities that sum to one.

Result: For any integer \(c\), $$ P(X>c)=1-P(X\leq c) =1-\sum_{k=0}^{\min(n,c)}P(X=k), $$ with a sum over no supported values taken as zero. Likewise, $$ P(X\geq c)=1-P(X\leq c-1). $$ These identities follow because \(\{X>c\}\) and \(\{X\leq c\}\) are disjoint and together contain every possible value of \(X\); the second identity uses the fact that \(X\) is integer-valued.

Worked Example: Comparing Strict and Inclusive Upper Tails

Suppose \(X\sim\operatorname{Bin}(5,0.4)\). Calculate \(P(X>2)\) and \(P(X\geq2)\), and compare them.

For the strict event \(X>2\), the possible values are \(3,4,5\). Their probabilities are $$ \begin{aligned} P(X=3)&=\binom{5}{3}(0.4)^3(0.6)^2=10(0.064)(0.36)=0.2304,\\ P(X=4)&=\binom{5}{4}(0.4)^4(0.6)=5(0.0256)(0.6)=0.0768,\\ P(X=5)&=\binom{5}{5}(0.4)^5=0.01024. \end{aligned} $$ Thus, $$ P(X>2)=0.2304+0.0768+0.01024=0.31744. $$

For the inclusive event \(X\geq2\), add the mass at \(2\): $$ P(X=2)=\binom{5}{2}(0.4)^2(0.6)^3 =10(0.16)(0.216)=0.3456. $$ Therefore, $$ P(X\geq2)=P(X=2)+P(X>2)=0.3456+0.31744=0.66304. $$

This result can be checked using the complement. The excluded values are \(0\) and \(1\): $$ P(X=0)=(0.6)^5=0.07776,\qquad P(X=1)=\binom{5}{1}(0.4)(0.6)^4=0.2592. $$ Hence \(P(X\geq2)=1-(0.07776+0.2592)=0.66304\), agreeing with the direct calculation. The strict and inclusive tails differ by \(P(X=2)=0.3456\).

Boundary Checks and a Common Pitfall

Before calculating, compare the event with the support \(0,\ldots,n\). For example, \(P(X\geq n+1)=0\), while \(P(X\geq0)=1\). A requested interval that contains no supported integer also has probability zero. These checks can catch an error before any arithmetic is done.

A common mistake is to read \(X>2\) as though it meant \(X\geq2\). That reasoning includes the value \(2\), even though the strict inequality excludes it. The correction is to translate the event into supported integers first: \(X>2\) means \(X\in\{3,4,\ldots,n\}\), while \(X\geq2\) means \(X\in\{2,3,\ldots,n\}\). The difference between the two probabilities is exactly \(P(X=2)\).

Another tempting shortcut is to use a complement without writing the complementary event. For instance, the complement of \(X>2\) is \(X\leq2\), not \(X\leq1\). Writing the event and its complement explicitly keeps the endpoint in the right place.

1
Translate the wording.
Write the event as an inequality and identify which integer values it includes.
2
Check the support.
Discard values below \(0\) or above \(n\); if none remain, the probability is zero.
3
Choose a calculation.
Use one mass for a point, a finite sum for an interval or tail, or a complement when it involves fewer terms.
4
Check the result.
Confirm that the included endpoint masses match the wording and that the probability lies between zero and one.

These calculations are basic building blocks for using a binomial model in statistical work. Point probabilities answer questions about an exact count; interval probabilities answer questions about counts within an acceptable range; and tail probabilities quantify counts unusually low or high relative to a stated threshold. The interpretation depends on the model, while the arithmetic depends on translating the event correctly.

Check Your Understanding

For each question, identify the relevant integer counts before calculating.

  1. If \(X\sim\operatorname{Bin}(6,0.5)\), which point probability gives the chance of exactly four successes?
  2. If \(X\sim\operatorname{Bin}(8,0.25)\), which integer values are included in \(P(2<X\leq5)\)?
  3. For an integer \(c\), state the complement of the event \(X\geq c\).
  4. If \(X\sim\operatorname{Bin}(4,0.3)\), what is \(P(X>4)\), and why?
  5. Explain why \(P(X>2)\) and \(P(X\geq2)\) differ by exactly one point probability.