rNMNOrep: Generation random deviates of the replicated number of...

Description Usage Arguments Details Value References See Also Examples

Description

Generate random deviates of the number N^{\textrm{MNO, rep}} of individuals according to the MNO according to the original number of individuals N^{\textrm{MNO}} detected by the MNO

Usage

1
2
3
rNMNOrep(n, nMNO, nReg, fu, fv, flambda, relTol = 1e-06, nSim = 1e+06,
  nStrata = c(1, 100, 100), verbose = FALSE,
  nThreads = RcppParallel::defaultNumThreads())

Arguments

n

number of points to generate

nMNO

non-negative integer vectors with the number of individuals detected according to the network operator

nReg

non-negative integer vectors with the number of individuals detected according to the population register

fu

named list with the prior marginal distribution of the parameter u

fv

named list with the prior marginal distributions of the parameter v

flambda

named list with the prior distribution of the parameter λ

relTol

relative tolerance in the computation of the kummer function. Default value is 1e-6

nSim

number of two-dimensional points to generate to compute the integral. Default value is 1e4

nStrata

integer vector of length 3 with the number of strata in each dimension. Default value is c(1, 1e2, 1e2)

verbose

logical (default FALSE) to report progress of the computation

nThreads

number (default the number of all cores, including logical cores) to use for computation

Details

The prior distributions are specified as named lists where the first component of each list must be the name of distribution ('unif', 'triang', '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

rMNOrep returns a data.table with the values of generated points (column nMNO) for each value of the parameters u, v, λ together with priors for the hierarchical model.

References

https://github.com/MobilePhoneESSnetBigData

See Also

rNMNO

Examples

1
2
3
4
rNMNOrep(10, nMNO = 15, nReg = 110, 
         fu = list('unif', xMin = 0.1, xMax = 0.2),
         fv = list('unif', xMin = 100, xMax = 120),
         flambda = list('gamma', shape = 11, scale = 110 / 10))

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