rp: Generate random vector deviates of transition probabilities.

Description Usage Arguments Details Value Examples

Description

Generate random vector deviates of the transition probabilities p_{ij}(t_{0}, t_{n}) for a given cell i stacked into an n\times(number of cells) matrix

Usage

1
rp(n, flist)

Arguments

n

number of probability vectors to generate

flist

list with the prior distributions for each cell

Details

The prior distributions are specified as named lists where the first component of each list must be the name of distribution ('unif', 'triang', 'degen', 'gamma') and the rest components must be named according to the name of the parameters of the random generator of the corresponding distribution according to:

Value

Return a matrix with n rows and as many columns as cells taken from the length of flist. Each row is thus a probability vector

Examples

1
2
3
flist <- alphaPrior(c(10, 3, 4), c('unif', 'triang', 'gamma'),
       list(list(cv = 0.1), list(cv = 0.05), list(cv = 0.15)))
rp(10, flist)

MobilePhoneESSnetBigData/pestim documentation built on May 31, 2019, 2:44 p.m.