Correction to Bayes Notebook 1
Closed this issue · 2 comments
@fonnesbeck, I was watching the scipy 2014 video and went through the first notebook (on Bayes). I think there is a switch on the first introduction/application of bayes rule. I corrected the markdown I'm referring to and pasted it here. Basically every single P(A|B) should've been a P(B|A).
[\begin{aligned}
L(s_1=0, s_2=0 &| W=1) = (0.5)(0.5) = 0.25 \cr
L(s_1=0, s_2=0 &| W=0) = (1)(1) = 1
\end{aligned}]
[\begin{aligned}
Pr(W=1 | s_1=0, s_2=0) &= \frac{L(s_1=0, s_2=0 | W=1) Pr(W=1)}{L(s_1=0, s_2=0 | W=1) Pr(W=1) + L(s_1=0, s_2=0 | W=0) Pr(W=0)} \cr
&= \frac{(0.25)(0.5)}{(0.25)(0.5) + (1)(0.5)} \cr
&= 0.2
\end{aligned}]
No, this is just a notational convention. If I'm talking about the likelihood L(a|b), that is the same as the probability Pr(b|a), because the likelihood function is the same as the probability distribution (mass) function, just with the conditioning reversed. You don't talk about the likelihood of the data given the parameters (which is what you have written), you talk about the likelihood of the parameters given the data.
@fonnesbeck this helps very much thank you -- my teammate and I were confused...