Tutorials › AP Statistics › Probabilities Between Two Values for Binomial Variables

Binomial distributions · Tutorial 350 of 1000

Probabilities Between Two Values for Binomial Variables

Use two cumulative binomial probabilities to find the chance that a count falls between an inclusive lower and upper bound.

Intermediate 9 min read

What You'll Learn

  • Translate an inclusive binomial range into an inequality for the random variable.
  • Find the correct lower cutoff by subtracting one from the range’s lower endpoint.
  • Calculate a range probability by subtracting two binomcdf values.
  • Check a range calculation by adding the probabilities of its individual counts.
  • Identify endpoint and calculator-cutoff mistakes that can change the event.

From One-Sided Probabilities to a Range

In Finding At Least Probabilities with binomcdf, you used a cumulative probability to find an upper-tail probability by subtracting from 1. A range probability uses a related idea: find the cumulative probability up to the range’s upper endpoint, then subtract the cumulative probability for counts below its lower endpoint.

Suppose \(X\) is a binomial random variable and the question asks for the probability that \(X\) is at least \(a\) and at most \(b\). For integer endpoints, the event is \(a\leq X\leq b\). The cumulative probability \(P(X\leq b)\) includes every count from zero through \(b\). To leave only the counts from \(a\) through \(b\), remove the counts below \(a\), namely \(X\leq a-1\).

Formula: For a binomial random variable \(X\) and whole-number bounds \(a\leq b\):
$$ \begin{aligned} P(a\leq X\leq b) &=P(X\leq b)-P(X\leq a-1)\\ &=\operatorname{binomcdf}(n,p,b) -\operatorname{binomcdf}(n,p,a-1). \end{aligned} $$

The upper cutoff is \(b\), because the requested range includes \(b\). The lower cutoff is \(a-1\), because that cumulative probability contains exactly the counts that must be excluded. This “one below the lower endpoint” is the key detail.

As in Using binomcdf for At Most Probabilities, \(\operatorname{binomcdf}(n,p,k)\) gives \(P(X\leq k)\). It includes the cutoff \(k\), so subtracting \(P(X\leq a-1)\) removes the counts below \(a\) without removing \(a\) itself. Before using the calculator, define \(X\) and check the binomial conditions with BINS, as in the earlier tutorials.

A Reliable Range Calculation

A range can be read as a portion of the cumulative distribution. For example, if the desired counts are 3, 4, 5, and 6, then \(P(X\leq 6)\) includes those counts plus 0, 1, and 2. Subtracting \(P(X\leq 2)\) leaves just 3 through 6.

1
Define the count and translate the wording.
Write what \(X\) counts and express the requested range as \(a\leq X\leq b\).
2
Find the two cumulative cutoffs.
Use \(b\) as the upper cutoff and \(a-1\) as the cutoff below the lower endpoint.
3
Subtract the cumulative probabilities.
Calculate \(\operatorname{binomcdf}(n,p,b)-\operatorname{binomcdf}(n,p,a-1)\).
4
Check and interpret.
Confirm the endpoints are included as intended, then describe the probability in context.

If the bounds are whole numbers within the possible values \(0\) through \(n\), the formula applies directly. If a word problem gives non-integer bounds, remember that a binomial count can only be a whole number. For example, \(2.4\leq X\leq 5.8\) selects the integer counts 3, 4, and 5, so the event is equivalent to \(3\leq X\leq 5\).

Worked Example: A Range of Successful Sensor Readings

Worked Example: A Range of Successful Sensor Readings

A quality-control model assigns each sensor reading a 0.25 probability of being flagged, independently from other readings. Twelve readings are checked. Let \(X\) be the number flagged. Find the probability that between 3 and 6 readings, inclusive, are flagged.

State. The requested event is \(3\leq X\leq 6\). The count \(X\) follows a binomial model with \(n=12\) and \(p=0.25\), provided the stated model is appropriate.

Plan. BINS is satisfied under the model: each reading has two outcomes (flagged or not flagged); readings are stated to be independent; the number of trials is fixed at 12; and the probability of being flagged is the same, 0.25, for each reading. The upper cumulative cutoff is 6. The counts below the range are 0, 1, and 2, so the lower cumulative cutoff is \(3-1=2\). Subtract the cumulative probability through 2 from the cumulative probability through 6.

Do. Using \(\operatorname{binomcdf}\), the calculator gives \(P(X\leq 6)\approx 0.9857\) and \(P(X\leq 2)\approx 0.3907\), each rounded to four decimal places. Keep full calculator precision for the subtraction before rounding the final probability:

$$ \begin{aligned} P(3\leq X\leq 6) &=\operatorname{binomcdf}(12,0.25,6) -\operatorname{binomcdf}(12,0.25,2)\\ &\approx 0.9857472-0.3906750\\ &\approx 0.5950722\\ &\approx 0.5951. \end{aligned} $$

The displayed cumulative probabilities rounded to four decimal places are 0.9857 and 0.3907. Subtracting only those rounded displays gives 0.5950; that small discrepancy is due to rounding. The final result, 0.5951, comes from subtracting the calculator values before rounding.

A check is to add the probabilities of exactly 3, 4, 5, and 6 flagged readings. Using the binomial model, the individual probabilities rounded to four decimal places are \(P(X=3)\approx 0.2581\), \(P(X=4)\approx 0.1936\), \(P(X=5)\approx 0.1032\), and \(P(X=6)\approx 0.0401\). Adding the unrounded probabilities gives approximately 0.5950722, or 0.5951. Adding the rounded displays alone can differ slightly because each term has already been rounded.

Conclude. According to this model, the probability that between 3 and 6 of the 12 readings, inclusive, are flagged is about 0.5951, or 59.51%.

This example shows why the lower cutoff is 2 rather than 3. The cumulative probability through 3 includes the count \(X=3\), which belongs in the requested range. Subtracting through 3 would remove that valid endpoint.

Worked Example: A Range of Successful Practice Shots

Worked Example: A Range of Successful Practice Shots

A player models each practice shot as having a 0.50 probability of hitting a target, independently of the other shots. The player takes eight shots. Let \(X\) be the number of hits. Find the probability of getting between 2 and 5 hits, inclusive.

Define and check. Here, \(X\) counts hits in \(n=8\) trials, with \(p=0.50\). Each shot has two outcomes (hit or miss), the shots are modeled as independent, the number of shots is fixed, and the hit probability is constant. All four BINS conditions are met under the stated model.

Translate and calculate. The event is \(2\leq X\leq 5\). Use the cumulative cutoff 5 for the upper endpoint and \(2-1=1\) for counts below the range:

$$ \begin{aligned} P(2\leq X\leq 5) &=\operatorname{binomcdf}(8,0.50,5) -\operatorname{binomcdf}(8,0.50,1)\\ &=0.85546875-0.03515625\\ &=0.8203125\\ &\approx 0.8203. \end{aligned} $$

The result can be checked using the binomial probabilities for 2, 3, 4, and 5 hits. Because \(p=0.50\), the probabilities are the corresponding combination counts divided by \(2^8=256\):

$$ \begin{aligned} P(2\leq X\leq 5) &=\frac{\binom{8}{2}+\binom{8}{3}+\binom{8}{4}+\binom{8}{5}}{256}\\ &=\frac{28+56+70+56}{256}\\ &=\frac{210}{256}\\ &=0.8203125. \end{aligned} $$

Interpret. Under the model, the probability that the player hits the target on 2, 3, 4, or 5 of the eight practice shots is about 0.8203, or 82.03%.

The direct check and the cumulative subtraction agree. The check also makes the endpoints visible: there are four included counts, beginning at 2 and ending at 5.

Worked Example: Seedlings That Sprout

Worked Example: Seedlings That Sprout

A gardener uses a model in which each seed has a 0.50 probability of sprouting, independently of the other seeds. Six seeds are planted. Let \(X\) be the number that sprout. Find the probability that from 1 through 4 seeds, inclusive, sprout.

Identify the event and conditions. The event is \(1\leq X\leq 4\). Each seed either sprouts or does not sprout, there are a fixed six seeds, the model assumes the outcomes are independent, and it assigns the same probability \(p=0.50\) to each seed. These satisfy BINS under the stated model.

Calculate. The cumulative probability through 4 includes 0 through 4 sprouts. Subtract the probability through \(1-1=0\) to remove the zero-sprout outcome:

$$ \begin{aligned} P(1\leq X\leq 4) &=\operatorname{binomcdf}(6,0.50,4) -\operatorname{binomcdf}(6,0.50,0)\\ &=0.890625-0.015625\\ &=0.875\\ &=0.8750. \end{aligned} $$

For a check, the excluded possible counts are 0, 5, and 6. Their probabilities are \(1/64\), \(6/64\), and \(1/64\), respectively. Thus the probability of the requested range is \(1-(1+6+1)/64=56/64=0.8750\).

Interpret. According to this model, there is an 87.50% probability that between 1 and 4 of the six seeds, inclusive, will sprout.

Common Mistakes and Full-Credit Communication

The main challenge is not the subtraction itself; it is matching both cutoffs to the event. A quick endpoint check can prevent most errors: the count \(a\) must remain in the answer, and the count \(b\) must remain in the answer. Counts below \(a\) should be removed, but \(a\) should not be removed.

  • Using \(a\) as the lower cumulative cutoff. Subtracting \(P(X\leq a)\) removes the count \(a\) as well as the smaller counts. For an inclusive lower endpoint \(a\), subtract \(P(X\leq a-1)\).
  • Subtracting in the wrong order. The cumulative probability through \(b\) is at least as large as the cumulative probability through \(a-1\). Subtract the smaller lower cumulative probability from the upper one.
  • Misreading an endpoint. “At least \(a\) and at most \(b\)” includes both endpoints. In contrast, “more than \(a\)” excludes \(a\); translate the wording into an inequality before entering a command.
  • Rounding too early. Keep calculator precision during the subtraction and round the final result. If separately rounded cumulative probabilities are subtracted, the displayed difference may not match the correctly rounded final answer.
  • Reporting a number without context. State what \(X\) counts and interpret the result as the probability of the requested range in the setting. A calculator value alone does not explain the event.

For a full-credit explanation, show the event, identify the two cumulative cutoffs, write the subtraction, and interpret the result in context. For example: “The event is \(3\leq X\leq 6\). Counts below the range satisfy \(X\leq 2\), so \(P(3\leq X\leq 6)=\operatorname{binomcdf}(n,p,6)-\operatorname{binomcdf}(n,p,2)\). The resulting probability describes the chance of 3 through 6 successes, inclusive.” In a real setting, also state why a binomial model is appropriate, using BINS.

AP Exam Tip: Write \(P(a\leq X\leq b)=P(X\leq b)-P(X\leq a-1)\) before entering the calculator command. The lower cutoff is one less than the requested lower endpoint because the event includes that endpoint.

Key Takeaway

A binomial range probability is the difference between two cumulative probabilities. The upper cumulative cutoff is the range’s upper endpoint; the lower cumulative cutoff is one less than its lower endpoint.

Key takeaway: For inclusive whole-number bounds, calculate \(\operatorname{binomcdf}(n,p,b)-\operatorname{binomcdf}(n,p,a-1)\). Keep the calculator’s full precision through subtraction, then round and interpret the result in context.

Check Your Understanding

For each question, write the event and identify both cumulative cutoffs before calculating.

  1. A binomial random variable has \(n=9\) and \(p=0.30\). Write a calculator command for the probability that \(X\) is between 2 and 5, inclusive.
  2. What event does \(\operatorname{binomcdf}(10,0.20,6)-\operatorname{binomcdf}(10,0.20,2)\) represent? Write the inequality for \(X\).
  3. Explain why \(\operatorname{binomcdf}(12,0.25,6)-\operatorname{binomcdf}(12,0.25,3)\) does not find \(P(3\leq X\leq 6)\).
  4. For \(n=8\) and \(p=0.50\), write the command for the probability of between 1 and 4 successes, inclusive.
  5. A model gives a probability of 0.8203 for a count to fall from 2 through 5. What does that probability mean in context if \(X\) counts successful practice shots?