80 likes | 225 Views
Bayesian analysis with a discrete distribution. Source: Stattrek.com. Bayes Theorem. Probability of event A given event B depends not only on the relationship between A and B but on the absolute probability of A not concerning B and the absolute probability of B not concerning A.
E N D
Bayesian analysis with a discrete distribution Source: Stattrek.com
Bayes Theorem • Probability of event A given event B depends not only on the relationship between A and B but on the absolute probability of A not concerning B and the absolute probability of B not concerning A. Start with --P(Ak∩B)=P(Ak).P(B|Ak)
Bayes Theorem • If A1, A2, A3…An are mutually exclusive events of sample space S and B is any event from the same sample space and P(B)>0. then, • P(Ak|B)= P(Ak). P(B|Ak) P(A1). P(B|A1)+P(A2). P(B|A2)+… P(An). P(B|An)
Sufficient conditions for Bayes • The sample space is partitioned into a set of mutually exclusive events { A1, A2, . . . , An }. • Within the sample space, there exists an event B, for which P(B) > 0. • The analytical goal is to compute a conditional probability of the form: P( Ak | B ). • We know at least one of the two sets of probabilities described below. • P( Ak ∩ B ) for each Ak • P( Ak ) and P( B | Ak ) for each Ak
Eg. of Discrete Distribution • Marie is getting married tomorrow, at an outdoor ceremony in the desert. In recent years, it has rained only 5 days each year.
Eg. of Discrete Distribution • The weatherman has predicted rain for tomorrow. • When it actually rains, the weatherman correctly forecasts rain 90% P( B | A1 )of the time. • When it doesn't rain, he incorrectly forecasts rain 10% P( B | A2 ) of the time. • What is the probability that it will rain on the day of Marie's wedding (P(A1))? • A2==does not rain on wedding.
Values for calculation • 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.]
Applying the Bayes theorem • P(Ak|B)= P(Ak). P(B|Ak) P(A1). P(B|A1)+P(A2). P(B|A2)+… P(An). P(B|An) • P(A1|B)= P(A1). P(B|A1) P(A1). P(B|A1)+P(A2). P(B|A2) • P(A1|B)= 0.111