Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- m = 10^6 # iterations
- x = rgeom(m, 1/3)+1; y = rgeom(m, 1/3)+1 # independent counts of 'trials'
- mean(x == y)
- ## 0.200079 # Consistent with P(X = Y) = 1/5
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement