Estimate marginal variances of a (I)GMRF prior defined in terms of a sparse precision matrix and possibly a set of equality constraints. The marginal variances might be used to rescale the precision matrix such that a default prior for a corresponding variance component is more appropriate.
sim_marg_var(
D,
Q = NULL,
R = NULL,
r = NULL,
eps1 = 1e-09,
eps2 = 1e-09,
nSim = 100L
)
A vector of Monte Carlo estimates of the marginal variances.
factor of precision matrix Q such that Q=D'D.
precision matrix.
equality restriction matrix.
rhs vector for equality constraints \(R'x = r\), where \(R'\) denotes the transpose of R.
passed to create_cMVN_sampler
.
passed to create_cMVN_sampler
.
number of Monte Carlo samples used to estimate the marginal variances.
S.H. Sorbye and H. Rue (2014). Scaling intrinsic Gaussian Markov random field priors in spatial modelling. Spatial Statistics, 8, 39-51.