shape and scale parameters. Must be positive, scale strictly
rate
an alternative way to specify the scale
log
logical; if TRUE, probabilities/densities p are returned as log(p)
type
specify the type; may be "double", "single" (or short form "d" or "s")
Value
gdgamma gives the density and grgamma generates random deviates.
Details
Works in much the same way as the R base functions.
References
Random gamma simulation was implemented using the algorithm described in:
Marsaglia and Tsang (2000) A Simple Method for Generating Gamma Variables. ACM Transactions on Mathematical Software. Volume 26 Issue 3, Pages 363-372.