WAIC: Watanabe-Akaike information criteria

Description Usage Arguments Details Value References Examples

Description

Sort and display the Watanabe-Akaike information criteria of INLA models.

Usage

1
WAIC(..., decreasing = FALSE, rnd = 3)

Arguments

...

objects of class inla with computed WAIC.

decreasing

logical. If FALSE (default), WAIC's are displayed in increasing order.

rnd

integer indicating the number of decimal places to be used.

Details

control.compute = list(waic = TRUE) must be used within inla function.

Value

matrix with models' WAIC.

References

Gelman, Andrew, Jessica Hwang, and Aki Vehtari. "Understanding predictive information criteria for Bayesian models." Statistics and Computing 24.6 (2014): 997-1016.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
data(sp)

mod1 <- inla(aan ~ f(id, model = 'bym', graph = sp.adj),
             family = 'poisson', data = spn, E = eaan,
             control.compute = list(waic = TRUE))

mod2 <- inla(aan ~ shvn + f(id, model = 'bym', graph = sp.adj),
             family = 'poisson', data = spn, E = eaan,
             control.compute = list(waic = TRUE))

WAIC(mod1, mod2)

oswaldosantos/INLAOutputs documentation built on May 24, 2019, 5 p.m.