duvlambda: Posterior density function of the parameters u, v, and...

Description Usage Arguments Details Value See Also Examples

Description

Compute the unnormalized posterior density function of the parameter λ in the hierarchical model.

Usage

1
2
duvlambda(lambda, u, v, nMNO, fu, fv, flambda, relTol = 1e-06,
  nThreads = RcppParallel::defaultNumThreads())

Arguments

lambda

values of the parameter λ

u

values of the parameter u

v

values of the parameter v

nMNO

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

fu

named list with the prior marginal distributions of the hyperparameter u

fv

named list with the prior marginal distributions of the hyperparameter v

flambda

named list with the prior marginal distribution of the parameter λ

relTol

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

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 density/probability function of the corresponding distribution according to:

Value

duvlambda returns the probability mass function of the number of indviduals detected by the mobile network operator according to the hierarchical model. It depends on priors for the parameters

u

,

v

,

λ

.

See Also

dlambda

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
f <- function(x){duvlambda(x, 0.346, 97, 19, 
           fu = list('unif', xMin = 0.3, xMax = 0.4),
           fv = list('unif', xMin = 90, xMax = 105),
           flambda = list('gamma', shape = 11, scale = 97 / 10))$prob}
curve(f, 0, 150)

f <- function(x){duvlambda(70, x, 97, 19, 
           fu = list('unif', xMin = 0.3, xMax = 0.4),
           fv = list('unif', xMin = 90, xMax = 105),
           flambda = list('gamma', shape = 11, scale = 97 / 10))$prob}
curve(f, 0, 1)

f <- function(x){duvlambda(70, 0.35, x, 19, 
           fu = list('unif', xMin = 0.3, xMax = 0.4),
           fv = list('unif', xMin = 90, xMax = 105),
           flambda = list('gamma', shape = 11, scale = 97 / 10))$prob}
curve(f, 80, 115)

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