Learn R Programming

INLAtools (version 0.0.8)

Functionalities for the 'INLA' Package

Description

Contain code to work with a C struct, in short cgeneric, to define a Gaussian Markov random (GMRF) model. The cgeneric contain code to specify GMRF elements such as the graph and the precision matrix, and also the initial and prior for its parameters, useful for model inference. It can be accessed from a C program and is the recommended way to implement new GMRF models in the 'INLA' package (). The 'INLAtools' implement functions to evaluate each one of the model specifications from R. The implemented functionalities leverage the use of 'cgeneric' models and provide a way to debug the code as well to work with the prior for the model parameters and to sample from it. A very useful functionality is the Kronecker product method that creates a new model from multiple cgeneric models. It also works with the rgeneric, the R version of the cgeneric intended to easy try implementation of new GMRF models. The Kronecker between two cgeneric models was used in Sterrantino et. al. (2024) , and can be used to build the spatio-temporal intrinsic interaction models for what the needed constraints are automatically set.

Copy Link

Version

Install

install.packages('INLAtools')

Monthly Downloads

5,912

Version

0.0.8

License

GPL (>= 2)

Issues

Pull Requests

Stars

Forks

Maintainer

Elias Teixeira Krainski

Last Published

February 2nd, 2026

Functions in INLAtools (0.0.8)

upperPadding

Padding (a list of) sparse matrices.
Sparse

To store in i,j,x sparse matrix format
findGetFunction

Search a function and retrieve it.
INLAtools-methods

Methods to work with a model.
is.zero

Define the is.zero method
cgeneric-class

Organize data for the latent GMRF C interface for INLA.
multi_generic_model

Combine two or more cgeneric or rgeneric models
kronecker

cgeneric_generic0

Build an cgeneric object for a generic0 model. See details.
extraconstr

rgeneric_get

rgeneric_get is an internal function used by graph, pred, initial, mu or prior methods for rgeneric.
packageCheck

To check package version and load
rgeneric-class

Organize data for the latent GMRF R interface for INLA.
prec.inla

Define the prec method for an inla output object
cgeneric_get

cgeneric_get is an internal function used by graph, pred, initial, mu or prior methods for cgeneric.