Does Bayes theorem have two formulas?

475 Views Asked by At

$$P(AlB)=P(A)P(B\mid A)/[P(A)P(B \mid A)+P(A^c)P(B \mid A^c)] $$

$$P(A \mid B) = [P(B \mid A)P(A)]/P(B)$$

1) Are these two equations so called bayes formula??

2) how do you distinguish whether to use the first one or the second one?

3) If i assume A and B are independent, and let P(A)=0.2, P(B)=0.3 i get 0.2 using both equations. but what if A and B are dependent? how would you calculate conditional probabilities such as $$P(B \mid A)$$

2

There are 2 best solutions below

1
On BEST ANSWER

The second equation is Bayes' theorem. I prefer to think of the theorem as written in the form $$\Pr[A \mid B]\Pr[B] = \Pr[A \cap B] = \Pr[B \mid A]\Pr[A],$$ because it is symmetric and easy to remember.

The first equation is simply the law of total probability applied to the denominator (the marginal distribution) of Bayes' theorem; i.e., for an even $A$ and its complement $\bar A$, $$\Pr[B] = \Pr[B \mid A]\Pr[A] + \Pr[B \mid \bar A]\Pr[\bar A].$$ These are two different concepts.

0
On

By the Law of Total Probability, the denominator of your first equation is equal to $P(B)$. Thus, the two equations are equivalent.