Skip to contents

Takes the riebler_gv of the generalised inverse, as implemented by INLA::inla.qinv. By default it is assumed that the graph is fully connected.

Usage

get_scale(Q, constraint = list(A = matrix(1, 1, nrow(Q)), e = 0))

Arguments

Q

A (square, symmetric) precision matrix.

constraint

A list with arguments A and e which imposes the constraint Au = e (where the precision of u is Q). See the ?INLA::f argument extraconstr. If constraint is the default value then this is a sum-to-zero constraint.

Examples

nb <- sf_to_nb(mw)
#> Error in .class1(object): object 'mw' not found
Q <- nb_to_precision(nb)
#> Error in nb_to_precision(nb): object 'nb' not found
get_scale(Q)
#> Error in nrow(Q): object 'Q' not found