Question 1209944: A coin has a probability 𝑝 of landing heads. It is flipped 10 times, resulting in 8 heads. Using Bayesian inference with the following prior information
(a) No prior knowledge about 𝑝.
(b) The coin is likely fair (𝑝 around 0.5).
(c) The coin is likely biased (𝑝 around 0 or 1).
(d) 𝑝 can only take one of three values: 0.2, 0.7, or 0.9.
(e) 𝑝 is restricted to the range 0.4 ≤ 𝑝 ≤ 0.9.
, answer the following questions:
(1) What is the estimated value of 𝑝?
(2) Is 𝑝 greater than 0.6?
The solution provided by @CPhill is completely incorrect.
Answer by ElectricPavlov(122) (Show Source):
You can put this solution on YOUR website! Let's break down each case using Bayesian inference:
**Likelihood:**
The likelihood of observing 8 heads in 10 flips is given by the binomial distribution:
$$L(p|X=8) = \binom{10}{8} p^8 (1-p)^2 = 45 p^8 (1-p)^2$$
**(a) No prior knowledge about 𝑝.**
* **Prior:** Uniform distribution over [0, 1], i.e., $P(p) \propto 1$.
* **Posterior:** $P(p|X=8) \propto L(p|X=8) \times P(p) \propto p^8 (1-p)^2$.
* **Estimated 𝑝:** To find the maximum, we differentiate and set to zero:
* $\frac{d}{dp} [p^8 (1-p)^2] = 0$
* This leads to $p = 8/10 = 0.8$.
* **(1) Estimated 𝑝 = 0.8**
* **(2) Yes, 𝑝 > 0.6**
**(b) The coin is likely fair (𝑝 around 0.5).**
* **Prior:** Beta distribution centered around 0.5, e.g., Beta(5, 5), so $P(p) \propto p^4(1-p)^4$.
* For the sake of simplicity I will use Beta(6,6), which is also centered at 0.5.
* **Posterior:** $P(p|X=8) \propto p^8 (1-p)^2 \times p^5 (1-p)^5 = p^{13} (1-p)^7$.
* **Estimated 𝑝:** Differentiate and set to zero:
* $\frac{d}{dp} [p^{13} (1-p)^7] = 0$
* This leads to $p = 13/20 = 0.65$.
* **(1) Estimated 𝑝 = 0.65**
* **(2) Yes, 𝑝 > 0.6**
**(c) The coin is likely biased (𝑝 around 0 or 1).**
* **Prior:** Beta distribution biased towards 0 or 1, e.g., Beta(9, 1). So $P(p) \propto p^8(1-p)^0$.
* **Posterior** $P(p|X=8) \propto p^8(1-p)^2 * p^8 = p^{16}(1-p)^2$.
* **Estimated p**
* $\frac{d}{dp}(p^{16}(1-p)^2) = 16p^{15}(1-p)^2-2p^{16}(1-p) = 0$
* $16(1-p)-2p = 0$
* $16-18p = 0$
* $p= 16/18 = 8/9 \approx 0.888$.
* **(1) Estimated 𝑝 ≈ 0.888**
* **(2) Yes, 𝑝 > 0.6**
**(d) 𝑝 can only take one of three values: 0.2, 0.7, or 0.9.**
* **Prior:** We assume a uniform prior, i.e., each value has equal probability.
* **Posterior:** Calculate the likelihood for each value:
* $L(0.2) = 45 (0.2)^8 (0.8)^2 \approx 1.15 \times 10^{-5}$
* $L(0.7) = 45 (0.7)^8 (0.3)^2 \approx 0.0307$
* $L(0.9) = 45 (0.9)^8 (0.1)^2 \approx 0.0194$
* **Estimated 𝑝:** The value with the highest likelihood is 0.7.
* **(1) Estimated 𝑝 = 0.7**
* **(2) Yes, 𝑝 > 0.6**
**(e) 𝑝 is restricted to the range 0.4 ≤ 𝑝 ≤ 0.9.**
* **Prior:** Uniform distribution over [0.4, 0.9].
* **Posterior:** $P(p|X=8) \propto p^8 (1-p)^2$ within the range [0.4, 0.9].
* **Estimated 𝑝:** From (a), the maximum likelihood occurs at 0.8, which is within the range.
* **(1) Estimated 𝑝 = 0.8**
* **(2) Yes, 𝑝 > 0.6**
**Summary:**
* **(a) 𝑝 = 0.8, Yes**
* **(b) 𝑝 = 0.65, Yes**
* **(c) 𝑝 ≈ 0.888, Yes**
* **(d) 𝑝 = 0.7, Yes**
* **(e) 𝑝 = 0.8, Yes**
|
|
|