poisson: The Poisson Distribution

Description Usage Arguments Details Value Note Author(s) See Also Examples

Description

Density and random generation for the Poisson distribution with parameter lambda.

Usage

1
2
gdpois(x, lambda, log = FALSE, type = "d")
grpois(n, lambda)

Arguments

x

vector of (non-negative integer) quantiles

n

number of random values to return

lambda

vector of (non-negative) means

log

logical; if TRUE, probabilities p are given as log(p)

type

specify the type; may be "double", "single" (or short form "d" or "s")

Details

Very similar to the R stats functionality.

Value

gdpois gives the (log) density, and grpois generates random deviates.

Note

The algorithm for simulating from the poisson distribution was modified from the GSL library which uses the Knuth method.

Author(s)

Nathan Morris

See Also

dpois

Examples

1
myRndNums = grpois(10,4)

gmatrix documentation built on May 29, 2017, 2:20 p.m.