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

component_list

Methods for inlabru component lists


Description

Constructor methods for inlabru component lists. Syntax details are given in component().

Usage

component_list(...)

## S3 method for class 'formula'
component_list(object, lhoods = NULL, envir = NULL, ...)

## S3 method for class 'list'
component_list(object, lhoods = NULL, envir = NULL, ...)

## S3 method for class 'component_list'
x[i]

Arguments

...

Parameters passed on to other methods

object

The object to operate on

lhoods

A bru_like_list object

envir

An evaluation environment to override the evaluation environment

x

component_list object from which to extract element(s)

i

indices specifying elements to extract

Details

  • component_list.formula: Convert a component formula into a component_list object

  • component_list.list: Combine a list of components and/or component formulas into a component_list object

Author(s)

Fabian E. Bachl bachlfab@gmail.com and Finn Lindgren finn.lindgren@gmail.com

See Also

Other component constructors: component()

Examples

# As an example, let us create a linear component. Here, the component is
# called "myLinearEffectOfX" while the covariate the component acts on is
# called "x". Note that a list of components is returned because the
# formula may define multiple components

eff <- component_list(~ myLinearEffectOfX(main = x, model = "linear"))
summary(eff[[1]])
# Equivalent shortcuts:
eff <- component_list(~ myLinearEffectOfX(x, model = "linear"))
eff <- component_list(~ myLinearEffectOfX(x))
# Individual component
eff <- component("myLinearEffectOfX", main = x, model = "linear")

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.