rGammaSD: Simulate gamma distributed stage durations.

Description Usage Arguments Value Examples

View source: R/functions.r

Description

The function is intended to be used in the calculation of Monte Carlo likelihoods.

Usage

1
rGammaSD(mu, cv, N)

Arguments

mu

A vector of length equal to one minus the number of stages giving the mean stage durations for all but the last stage.

cv

A vector of the same length as mu giving the coefficient of variation, which is equal to one over the square root of the shape, for all but the last stage.

N

The number of stage durations (individuals) to simulate.

Value

A matrix of stage durations where each row gives tha stage durations for one individual.

Examples

1
2
## Simulate gamma stage durations for ten individuals.
rGammaSD(mu = c(5,2,4), cv = c(1,.5,.3), N = 10)

jknape/stageFreq documentation built on May 19, 2019, 11:42 a.m.