Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

evaluate_predictor

Evaluate component effects or expressions


Description

Evaluate component effects or expressions, based on a bru model and one or several states of the latent variables and hyperparameters.

Usage

evaluate_predictor(model, state, data, effects, predictor, format = "auto")

Arguments

state

A list where each element is a list of named latent state information, as produced by evaluate_state()

data

A list, data.frame, or Spatial*DataFrame, with coordinates and covariates needed to evaluate the model.

effects

A list where each element is list of named evaluated effects, as computed by evaluate_effect_multi.component_list()

predictor

Either a formula or expression

format

character; determines the storage format of the output. Available options:

  • "auto" If the first evaluated result is a vector or single-column matrix, the "matrix" format is used, otherwise "list".

  • "matrix" A matrix where each column contains the evaluated predictor expression for a state.

  • "list" A list where each column contains the evaluated predictor expression for a state.

Default: "auto"

Value

A list or matrix is returned, as specified by format


inlabru

Bayesian Latent Gaussian Modelling using INLA and Extensions

v2.3.1
GPL (>= 2)
Authors
Finn Lindgren [aut, cre, cph] (<https://orcid.org/0000-0002-5833-2011>, Finn Lindgren continued development of the main code), Fabian E. Bachl [aut, cph] (Fabian Bachl wrote the main code), David L. Borchers [ctb, dtc, cph] (David Borchers wrote code for Gorilla data import and sampling, multiplot tool), Daniel Simpson [ctb, cph] (Daniel Simpson wrote the basic LGCP sampling method), Lindesay Scott-Howard [ctb, dtc, cph] (Lindesay Scott-Howard provided MRSea data import code), Seaton Andy [ctb] (Andy Seaton provided testing and bugfixes)
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.