b:head_first_statistics:calculating_probability
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
b:head_first_statistics:calculating_probability [2025/09/15 08:06] – [Probability magnet] hkimscil | b:head_first_statistics:calculating_probability [2025/09/22 08:31] (current) – [4] hkimscil | ||
---|---|---|---|
Line 84: | Line 84: | ||
</ | </ | ||
- | [{{: | + | [{{: |
<WRAP clear /> | <WRAP clear /> | ||
[{{: | [{{: | ||
Line 109: | Line 109: | ||
===== probability of A given B ===== | ===== probability of A given B ===== | ||
- | $ P(A \vert B) $ : The probability of A given that we know B has happened | + | $ P(A \mid B) $ : The probability of A given that we know B has happened |
\begin{eqnarray*} | \begin{eqnarray*} | ||
- | & & P(A \vert B) = \displaystyle \frac {P(A \cap B)}{P(B)} \\ | + | & & P(A \mid B) = \displaystyle \frac {P(A \cap B)}{P(B)} \\ |
- | & & P(B \vert A) = \displaystyle \frac {P(B \cap A)}{P(A)} \\ | + | & & P(B \mid A) = \displaystyle \frac {P(B \cap A)}{P(A)} \\ |
- | & & P(A \cap B) = P(A \vert B) * {P(B)} \\ | + | & & P(A \cap B) = P(A \mid B) * {P(B)} \\ |
- | & & P(B \cap A) = P(B \vert A) * P(A) \\ \\ | + | & & P(B \cap A) = P(B \mid A) * P(A) \\ \\ |
& & \text{since}, | & & \text{since}, | ||
Line 263: | Line 263: | ||
& = & \frac{5}{19} / \frac{9}{19} \\ | & = & \frac{5}{19} / \frac{9}{19} \\ | ||
& = & \frac{5}{19} * \frac{19}{9} \\ | & = & \frac{5}{19} * \frac{19}{9} \\ | ||
- | & = & \frac{10}{18} \\ | + | & = & \frac{5}{9} \\ |
\end{eqnarray*} | \end{eqnarray*} | ||
Line 277: | Line 277: | ||
<WRAP clear /> | <WRAP clear /> | ||
- | $$P(A \vert B) = \frac {P(A \cap B)}{P(B)} | + | \begin{eqnarray*} |
+ | & & P(A \mid B) = \frac {P(A \cap B)}{P(B)} | ||
+ | & & P(A \cap B) = P(B) * P(A \mid B) \\ | ||
+ | & & P(B \cap A) = P(A) * P(B \mid A) \\ | ||
+ | \\ | ||
+ | & & \therefore | ||
+ | & & P(A \cap B) = P(A) * P(B \mid A) \\ | ||
+ | \\ | ||
+ | & & \therefore \\ | ||
+ | & & P(A \mid B) = \frac {P(A) * P(B \mid A)} {P(B)} \\ | ||
+ | \\ | ||
+ | & & \text{also, } \because{} \\ | ||
+ | & & P(B) = P(A) * P(B \mid A) + P(\neg{A}) * P(B \mid \neg{A}) \\ | ||
+ | & & P(A \mid B) = \frac {P(A) * P(B \mid A)} {P(A) * P(B \mid A) + P(\neg{A}) * P(B \mid \neg{A})} \\ | ||
- | First, | + | \end{eqnarray*} |
- | $$ P(A \cap B) = P(A) * P(B \vert A) $$ | + | This is called "< |
- | For an easy way to understand, take a look at the tree. | + | |
- | + | ||
- | Then, find P(B), | + | |
- | IF we take a look at the picture, | + | |
- | $$ P(B) = P(A) * P(B \vert A) + P(A') * P(B \vert A' | + | |
- | + | ||
- | Hence, the answer is: | + | |
- | $$P(A \vert B) = \frac {P(A \cap B)}{P(B)} $$ | + | |
- | $$P(A \vert B) = \frac {P(A) * P(B \vert A)}{P(A) * P(B \vert A) + P(A') * P(B \vert A')} $$ | + | |
- | + | ||
- | + | ||
- | This is called "< | + | |
====== e.g. ====== | ====== e.g. ====== | ||
Line 328: | Line 329: | ||
$ P(A \cap B) = P(A) * P(B) $ | $ P(A \cap B) = P(A) * P(B) $ | ||
- | <WRAP box help> | ||
- | The Head First Health Club prides itself on its ability to find a class for everyone. As a result, it is extremely popular with both young and old. The Health Club is wondering how best to market its new yoga class, and the Head of Marketing wonders if someone who goes swimming is more likely to go to a yoga class. “Maybe we could offer some sort of discount to the swimmers to get them to try out yoga.” The CEO disagrees. “I think you’re wrong,” he says. “I think that people who go swimming and people who go to yoga are independent. I don’t think people who go swimming are any more likely to do yoga than anyone else.” They ask a group of 96 people whether they go to the swimming or yoga classes. Out of these 96 people, 32 go to yoga and 72 go swimming. 24 people are exceptionally eager and go to both. So who’s right? Are the yoga and swimming classes dependent or independent? | ||
- | </ | ||
* Throwing a coin and getting heads twice in a row. | * Throwing a coin and getting heads twice in a row. | ||
Line 343: | Line 341: | ||
<WRAP box help> | <WRAP box help> | ||
<fs large> | <fs large> | ||
- | |||
Three absent-minded friends decide to go out for a meal, but they forget where they’re going to meet. Fred decides to throw a coin. If it lands heads, he’ll go to the diner; tails, and he’ll go to the Italian restaurant. George throws a coin, too; heads, it’s the Italian restaurant; tails, it’s the diner. Ron decides he’ll just go to the Italian restaurant because he likes the food. | Three absent-minded friends decide to go out for a meal, but they forget where they’re going to meet. Fred decides to throw a coin. If it lands heads, he’ll go to the diner; tails, and he’ll go to the Italian restaurant. George throws a coin, too; heads, it’s the Italian restaurant; tails, it’s the diner. Ron decides he’ll just go to the Italian restaurant because he likes the food. | ||
- | What’s the probability all three friends meet? | + | - What’s the probability all three friends meet? |
+ | - What’s the probability one of them eats alone? | ||
+ | </ | ||
- | What’s the probability one of them eats alone? | + | < |
- | </WRAP> | + | |
<WRAP box help> | <WRAP box help> | ||
Line 357: | Line 355: | ||
* The probability of the ball landing in pockets 1, 2, 3, or 4. | * The probability of the ball landing in pockets 1, 2, 3, or 4. | ||
</ | </ | ||
+ | [{{: | ||
+ | <WRAP clear/> | ||
+ | ====== exercises ====== | ||
+ | ===== 1 ===== | ||
https:// | https:// | ||
+ | 아미라와 재인은 지각을 할 때가 있다. 전체 기간 중에는 70%는 둘 다 지각하지 않고 학교에 등교를 한다. 전체 기간 중에 아미라는 20% 지각을 하고 재인은 25% 지각을 한다. 지난 주 월요일에 재인은 지각을 했다. 아미라가 지각할 확률을 구하라. | ||
+ | ===== 2 ===== | ||
+ | |||
https:// | https:// | ||
- | https:// | + | 타냐는 테니스치는 것을 좋아하는데, |
+ | ===== 3 ===== | ||
- | https://wbd.ms/ | + | 불경기 대 톰은 직업을 잃을 확률이 40% 이다. 보통 때는 5%이다. |
+ | 해마다 불경기가 올 확률은 10% 라고 한다. | ||
+ | 작년에 톰은 직업을 읽었다. 이 때 불경기였을 확률은 얼마인가? | ||
- | + | ===== 4 ===== | |
- | Question | + | https:// |
- | * The probability of people having the disease is 10%. | + | * 사람들이 병에 걸릴 확률은 |
- | * The probability of test being correct is 80%. | + | * 병에 걸렸는지 확인하는 테스트가 맞을 경우는 |
- | * The test says that you have the disease. What is the chance you actually have the disease? | + | * 병원에 가서 테트스틀 해보니 병에 걸렸다고 한다. 실제 병에 걸렸을 확률은? |
{{: | {{: | ||
+ | |||
+ | ===== 5 ===== | ||
Question | Question | ||
Line 382: | Line 392: | ||
* 약물을 복용한다는 테스트 결과가 나왔는데, | * 약물을 복용한다는 테스트 결과가 나왔는데, | ||
* 이 확률 계산의 중요성에 (significance) 대해서 확인할 것 | * 이 확률 계산의 중요성에 (significance) 대해서 확인할 것 | ||
+ | ===== 6 ===== | ||
Question | Question |
b/head_first_statistics/calculating_probability.1757891183.txt.gz · Last modified: by hkimscil