ngvb - Latent Non-Gaussian Modelling with 'INLA' and Variational Bayes
Diagnoses whether the latent Gaussian assumption of a
model fitted with the 'INLA' package is adequate, and fits
latent non-Gaussian extensions that relax it. The function
ng.check() reports a Bayes-factor sensitivity diagnostic that
says whether, and where, the Gaussian assumption is inadequate;
ngvb() then fits the non-Gaussian model by a variational-Bayes
loop around 'INLA', adding local flexibility only where the
data support it. A single unified engine implements the
conditional precision Q(theta, V) = D(theta)^T diag(1/V)
D(theta) and owns its normalizing constant, and a model
registry covers iid, random-walk, autoregressive,
Ornstein-Uhlenbeck, intrinsic-CAR (besag),
simultaneous-autoregression, 'SPDE'/Matern and seasonal models.
Methods follow Cabral, Bolin and Rue (2024)
<doi:10.1080/01621459.2023.2296704> and Cabral, Bolin and Rue
(2025) <doi:10.1093/jrsssb/qkae107>.