User Tools

Site Tools


geometric_distribution

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
geometric_distribution [2025/10/11 03:11] hkimscilgeometric_distribution [2025/10/11 06:23] (current) hkimscil
Line 1: Line 1:
 ====== Geometric Distribution ====== ====== Geometric Distribution ======
 +기하분포
 +
 +\begin{align*}
 +\text{Geometric Distribution:  } \;\;\; \text{X} & \thicksim Geo(p) \\
 +p(X = k) & = q^{k-1} \cdot p \\
 +E\left[ X \right] & = \frac{1}{p} \\
 +V\left[ X \right] & = \frac{q}{p^2} \\
 +\\
 +\end{align*}
 +
 +====== Proof of mean and variance of geometric distribution ======
 +[[:Mean and Variance of Geometric Distribution]]
 +
 +
 {{youtube>zq9Oz82iHf0}} {{youtube>zq9Oz82iHf0}}
 +\\
 +\\
 +<WRAP clear/>
  
 +====== dgeom in r ======
 <code> <code>
 > dgeom(4, .2) > dgeom(4, .2)
Line 11: Line 29:
 </code> </code>
  
 +====== pgeom ======
 <code> <code>
 > pgeom(4, .2, lower.tail=T) > pgeom(4, .2, lower.tail=T)
Line 24: Line 43:
 > pgeom(4, .2, lower.tail=T)+pgeom(4, .2, lower.tail=F) > pgeom(4, .2, lower.tail=T)+pgeom(4, .2, lower.tail=F)
 [1] 1 [1] 1
- 
 </code> </code>
  
 +====== qgeom ======
 <code> <code>
 > qgeom(.5, .2) > qgeom(.5, .2)
Line 39: Line 58:
 > qgeom(.2, .2) > qgeom(.2, .2)
 [1] 0 [1] 0
 +
 +> qgeom(.16, .2)
 +[1] 0
 +> qgeom(.36, .2)
 +[1] 1
  
 </code> </code>
 +
 +====== rgeom ======
 +성공 확률이 .2 일 때 몇번 만에 성공할지 랜덤하게 구하는 것을 다섯 번 하라. 
 +<code>
 +> rgeom(5, .2)
 +[1] 5 6 5 0 8
 +
 +</code>
 +
 +====== e.g., ======
 +<WRAP box>
 +The probability that another snowboarder will make it down the slope without falling over is 0.4. Your job is to play like you’re the snowboarder and work out the following probabilities for your slope success.
 +
 +  - The probability that you will be successful on your second attempt, while failing on your first.
 +  - The probability that you will be successful in 4 attempts or fewer.
 +  - The probability that you will need more than 4 attempts to be successful.
 +  - The number of attempts you expect you’ll need to make before being successful.
 +  - The variance of the number of attempts.
 +</WRAP>
 +  - $P(X = 2) = p * q^{2-1}$
 +  - $P(X \le 4) = 1 - q^{4}$
 +  - $P(X > 4) = q^{4}$
 +  - $E(X) = \displaystyle \frac{1}{p}$
 +  - $Var(X) = \displaystyle \frac{q}{p^{2}}$
 +
 +
 +
 +
  
geometric_distribution.1760119860.txt.gz · Last modified: by hkimscil

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki