Skip to content
Back to formatted view

Raw Message

Message-ID: <Pine.A41.4.33.0110240734290.20192-100000@homer40.u.washington.edu>
Date: 2001-10-24T14:36:42Z
From: Thomas Lumley
Subject: generating a gamma random variable
In-Reply-To: <3BD6805E.7F7E65BC@pasteur.fr>

On Wed, 24 Oct 2001, Aboubakar Maitournam wrote:
> There is a way to simulate a gamma law of parameters a and b, based on
> the standard method above (simplified) and the variation of the method
> of rejection.


And there are source code and references for how R does it, yet another
different way, in src/nmath/rgamma.c

	-thomas

Thomas Lumley			Asst. Professor, Biostatistics
tlumley at u.washington.edu	University of Washington, Seattle

-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._