The Binomial distribution is one of the most frequently used discrete probability distributions. It describes the number of “successes” in a fixed number of independent trials, where each trial has the same probability of success.
To understand the Binomial distribution, we must first define a Bernoulli Trial. A Bernoulli trial is a random experiment with exactly two possible outcomes: 1. Success (S): Usually denoted by 1. 2. Failure (F): Usually denoted by 0.
Examples: * Tossing a coin (Heads or Tails). * Testing a product (Defective or Non-defective). * A medical treatment (Patient recovers or does not recover).
A random experiment is considered Binomial if it satisfies the following four conditions (BINS): 1. Binary: Outcomes are either success or failure. 2. Independent: The outcome of one trial does not affect another. 3. Number: There is a fixed number of trials (\(n\)). 4. Success: The probability of success (\(p\)) is the same for each trial.
If \(X\) is a random variable following a Binomial distribution, we denote it as: \[X \sim B(n, p)\]
The probability of getting exactly \(k\) successes in \(n\) trials is given by the formula:
\[P(X = k) = \binom{n}{k} p^k (1-p)^{n-k}\]
Where: * \(n\): Total number of trials. * \(k\): Number of successes (\(k = 0, 1, 2, ..., n\)). * \(p\): Probability of success on a single trial. * \((1-p) = q\): Probability of failure. * \(\binom{n}{k} = \frac{n!}{k!(n-k)!}\): The binomial coefficient (“n choose k”).
For a Binomial distribution \(X \sim B(n, p)\):
The shape of the Binomial distribution depends on the values of \(n\) and \(p\).
Observations: * When p < 0.5, the distribution is skewed to the right. * When p = 0.5, the distribution is perfectly symmetric. * When p > 0.5, the distribution is skewed to the left.
R provides four essential functions for the Binomial distribution:
dbinom(k, n, p): Probability Mass Function \(P(X = k)\).pbinom(k, n, p): Cumulative Distribution Function \(P(X \le k)\).qbinom(q, n, p): Quantile function (finds \(k\) such that \(P(X \le k) = q\)).rbinom(m, n, p): Generates \(m\) random variables from the
distribution.A factory produces light bulbs with a 5% defect rate (\(p = 0.05\)). If a sample of 10 bulbs is chosen at random, what is the probability that exactly 2 are defective?
Calculation: \(n = 10, k = 2, p = 0.05\)
## [1] 0.0746348
An email marketing campaign has a click-through rate (CTR) of 10%. If you send the email to 50 leads, what is the probability that more than 10 people click the link?
Calculation: We need \(P(X > 10)\), which is \(1 - P(X \le 10)\).
## [1] 0.009354602
A new drug has an 80% success rate in treating a specific condition. If 15 patients are treated, what is the expected number of recoveries?
Calculation: \(\mu = np = 15 \times 0.8 = 12\) The expected number of recoveries is 12.
| Feature | Description |
|---|---|
| Parameters | \(n\) (trials), \(p\) (probability of success) |
| Support | \(k \in \{0, 1, 2, ..., n\}\) |
| Symmetry | Symmetric if \(p=0.5\) |
| R Function (PMF) | dbinom() |
| R Function (CDF) | pbinom() |
```
File -> New File -> R Markdown...