Module 4. Assignment
A. Based on Table 1 What is the probability of:
| B | B1 | |
| A | 10 | 20 |
| A1 | 20 | 40 |
A1. Event A = P(A) = 30/90 = 1/3
A2. Event B? = P(B) = 30/90 = 1/3
A3. Event A or B = P(A or B) = P(A) + P(B) - P(A and B)
1/3 + 1/3 - 1/9 = 5/9
A4. P(A or B) = P(A) + P(B) = False, because P(A or B) = 5/9 and P(A) + P(B) = 2/3
B1. True
B2. We are given the following:
In terms of probabilities, we know the following:
P( A1 ) = 5/365 =0.0136985 [It rains 5 days out of the year.]
P( A2 ) = 360/365 = 0.9863014 [It does not rain 360 days out of the year.]
P( B | A1 ) = 0.9 [When it rains, the weatherman predicts rain 90% of the time.]
P( B | A2 ) = 0.1 [When it does not rain, the weatherman predicts rain 10% of the time.]
We want to know P( A1 | B ), the probability it will rain on the day of Marie's wedding, given a forecast for rain by the weatherman. The answer can be determined from Bayes' theorem, as shown below.
We want to know P( A1 | B ), the probability it will rain on the day of Marie's wedding, given a forecast for rain by the weatherman.
The formula is:
P( A1 | B) = P( B | A ) x P( A1 ) / P( A1) x P(B | A1) x P(A2) x P( B | A2 )
The numerator is P ( B | A) x P( A1) because it is a joint probability of both rain and the weatherman predicting rain, is represent by:
P( B | A ) x P( A1 )
The denominator is the total probability that the weatherman predicted rain, and it does rain, and it doesn't rain, which is represented by:
P( B | A1 ) x P( A1) x P( B | A2 ) x P( A2 )
Using the given, we plug everything in:
P( A1 | B ) = 0.9 x 0.0136985 / (0.9 + 0.0136985) + (0.1 x 0.9863014)
= 0.01232865 / 0.11095879
=0.111
= 11.1%
C.
> dbinom(10, size=10, prob=0.8)
[1] 0.1073742
Comments
Post a Comment