define_kernel {ipmr} | R Documentation |
Functions to initialize and define IPM kernels
Description
Adds a new kernel to the proto_ipm
structure.
Usage
define_kernel(
proto_ipm,
name,
formula,
family,
...,
data_list = list(),
states,
uses_par_sets = FALSE,
par_set_indices = list(),
age_indices = list(),
evict_cor = FALSE,
evict_fun = NULL,
integrate = TRUE
)
Arguments
proto_ipm |
The name of the model. |
name |
The name of the new kernel. |
formula |
A bare expression specifying the form of the kernel. |
family |
The type of kernel. Options are |
... |
A set of named expressions that correspond
to vital rates in |
data_list |
A list of named values that correspond to constants in the formula
and vital rate expressions in |
states |
A list with character vector containing the names of each state variable used in the kernel. |
uses_par_sets |
A logical indicating whether or not the parameters in the kernel and/or its
underlying vital rates are derived from sets. See the
introduction vignette for this feature for more details
( |
par_set_indices |
A named list with vectors corresponding to the values the index variable can take. The names should match the suffixes used in the vital rate expressions. |
age_indices |
If |
evict_cor |
A logical indicating whether an eviction correction should be applied to the kernel. |
evict_fun |
If |
integrate |
For |
Details
Different classes of IPMs may have many or only a few kernels. Each
one requires its own call to define_kernel
, though there are some exceptions,
namely for kernels derived for models derived from parameter sets (e.g. vital
rate models fit across plots and years).
A much more complete overview of how to generate kernels is provided in
vignette("ipmr-introduction", "ipmr")
.
Value
A proto_ipm
.