[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: Poisson Number Generation

From   "Austin Nichols" <>
Subject   Re: st: Poisson Number Generation
Date   Thu, 21 Feb 2008 09:15:32 -0500

findit gendist
findit rnd
and look inside the relevant ado code, e.g.
viewsource genpoisson.ado
viewsource rndpoix.ado

On Thu, Feb 21, 2008 at 8:45 AM, E. Paul Wileyto <> wrote:
> I don't think there is any way other than by brute force.  Generate the
>  uniform random number, and then go through the cumulative distribution
>  of Poisson counts with a lot of comparisons.  You will need to pick a
>  place to stop (largest count possible) or you could just keep going.
>  Logical functions will be more efficient than if/thens.
>  Martin Weiss wrote:
>  > to pick up the recent discussion of random number generation in Stata, how
>  > would one go about generating poisson random numbers without calling any
>  > external programs? I am certainly not as adept as others on the list
>  > inverting cumulative distribution functions, so I would appreciate any
>  > suggestions...
*   For searches and help try:

© Copyright 1996–2017 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index