[R] rgeom for p (1-p)^(x-1)

Charilaos Skiadas skiadas at hanover.edu
Wed Mar 14 13:51:51 CET 2007


On Mar 14, 2007, at 8:44 AM, Benjamin Dickgiesser wrote:
> Hi,
>
> is there a package available which lets me generate random data for
> the geometric distribution with density:
>
>  p(x) = p (1-p)^(x-1) ?
>
> rgeom uses the density p(x) = p (1-p)^x.

Why not just use rgeom, and then add 1 to all the values?

> Thank you,
> Benjamin

Haris Skiadas
Department of Mathematics and Computer Science
Hanover College



More information about the R-help mailing list