get.indiv: Get individual COD probabilities from InSilicoVA Model Fits

Description Usage Arguments Value Author(s) References See Also Examples

View source: R/get_indiv.r

Description

This function calculates individual probabilities for each death and provide posterior credible intervals for each estimates. The default set up is to calculate the 95

Usage

1
2
get.indiv(object, data = NULL, CI = 0.95, is.aggregate = FALSE,
  by = NULL, java_option = "-Xmx1g", ...)

Arguments

object

Fitted "insilico" object.

data

data for the fitted "insilico" object. The first column of the data should be the ID that matches the "insilico" fitted model.

CI

Credible interval for posterior estimates.

is.aggregate

logical indicator for constructing aggregated distribution rather than individual distributions.

by

list of column names to group by.

java_option

Option to initialize java JVM. Default to “-Xmx1g”, which sets the maximum heap size to be 1GB.

...

Not used.

Value

mean

individual mean COD distribution matrix.

median

individual median COD distribution matrix.

lower

individual lower bound for each COD probability.

upper

individual upper bound for each COD probability.

Author(s)

Zehang Li, Tyler McCormick, Sam Clark

Maintainer: Zehang Li <[email protected]>

References

Tyler H. McCormick, Zehang R. Li, Clara Calvert, Amelia C. Crampin, Kathleen Kahn and Samuel J. Clark Probabilistic cause-of-death assignment using verbal autopsies, arXiv preprint arXiv:1411.3042 http://arxiv.org/abs/1411.3042 (2014)

See Also

insilico, updateIndiv, plot.insilico

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
## Not run: 
data(RandomVA1)
fit1<- insilico(RandomVA1, subpop = NULL,
                Nsim = 1000, burnin = 500, thin = 10 , seed = 1,
                auto.length = FALSE)
summary(fit1, id = "d199")

# Calculate aggregated COD distributions
agg.csmf <- get.indiv(data = RandomVA1, fit1, CI = 0.95, 
                     is.aggregate = TRUE, by = NULL)
head(agg.csmf) 

agg.by.sex.age <- get.indiv(data = RandomVA1, fit1, CI = 0.95, 
                            is.aggregate = TRUE, by = list("sex", "age"))
head(agg.by.sex.age$mean) 

## End(Not run)

InSilicoVA documentation built on July 28, 2018, 5 p.m.