You poll 1000 people and ask 2 questions:
You get the following information - 10% of people get a heart attack - 60% of people who had a heart attack were not physically active - 70% of people who did not have a heart attack were physically active
\(P(attack) = 0.1\)
\(P(not~active|attack) = 0.6\)
\(P(active|no~attack) = 0.7\)
\(P(no~attack) = 0.9\)
\(P(active|attack) = 1 - 0.6 = 0.4\)
\(P(not~active|no~attack) = 1 - 0.7 = 0.3\)
First level: attack
yes (0.1)
no (0.9)
Second level: active|attack
yes|yes (0.4)
no|yes (0.6)
yes|no (0.7)
no|no (0.3)
\(P(active\cap attack) = 0.1 \cdot 0.4 = 0.04\)
\(P(not~active\cap attack) = 0.1 \cdot 0.6 = 0.06\)
\(P(active\cap no~attack) = 0.9 \cdot 0.7 = 0.63\)
\(P(not~active\cap no~attack) = 0.9 \cdot 0.3 = 0.27\)
\(P(attack) = 0.1\)
\(P(no~attack) = 0.9\)
\(P(active) = 0.04 + 0.63 = 0.67\)
\(P(not~active) = 0.06 + 0.27 = 0.33\)
\(P(attack|active) = 0.04/0.67 = 0.0597\)
\(E(X) = 0\cdot 0.9+1\cdot0.1 = 0.1\)
\(E(X) = 0\cdot(1-p)+1\cdot p = p\)
\(Var(X) = (0 - 0.1)^2\cdot0.9+(1-0.1)^2\cdot0.1 = 0.01\cdot0.9+0.81\cdot0.1 = 0.009+0.081 = 0.09\)
\(Var(X) = (0-p)^2\cdot (1-p)+(1-p)^2\cdot p = p^2\cdot(1-p)+(1-p)^2\cdot p = p\cdot(1-p)(p+1-p) = p\cdot(1-p)\)
You have a bag with 7 items, the probability of an item to be defective is 0.2.
Bernoulli with p = 0.2. X = 1 if defective and X = 0 if not defective.
Binomial with p = 0.2 and n = 7.
The probability is 0.1147
Use the table to draw the distribution diagram the number of defective items.
How would you use this table if I ask you to find the probability to have 3 out of 7 defective items if the probability for a an item to be defective is 0.8?
It is the same as the probability to have 4 out of 7 not defective* items if the probability for an item to be not defective is 0.2. Using the table we get 0.0287.