Learn R Programming

surveillance (version 1.23.1)

hhh4_W_utils: Extract Neighbourhood Weights from a Fitted hhh4 Model

Description

The getNEweights function extracts the (fitted) weight matrix/array from a "hhh4" object, after scaling and normalization. The coefW function extracts the coefficients of parametric neighbourhood weights from a hhh4 fit (or directly from a corresponding coefficient vector), i.e., coefficients whose names begin with “neweights”.

Usage

getNEweights(object, pars = coefW(object),
             scale = ne$scale, normalize = ne$normalize)
coefW(object)

Arguments

object

an object of class "hhh4". coefW also works with the coefficient vector.

pars

coefficients for parametric neighbourhood weights, such as for models using W_powerlaw. Defaults to the corresponding point estimates in object.

scale,normalize

parameters of the ne component of hhh4.

Author

Sebastian Meyer