Select parameters to include
include_pars.RdHelper function to amend a vector of parameter names or hierarchical level shortcuts.
Arguments
- pars
A character vector specifying (hyper)parameters, states, and/or quantities of interest ("parameters"). Parameters can be explicitly named or one or more shortcuts can be used to specify hierarchical levels of parameters; see
stan_pars()for details.- stan_model
Character string specifying the salmonIPM model to be fit. A more concise alternative to specifying
model,life_cycle, andpool_popsand will override those arguments.- SR_fun
One of
"exp"(density-independent discrete exponential),"BH"(Beverton-Holt, the default), or"Ricker", indicating which spawner-recruit function to fit. Synonyms"DI","B-H","bh","b-h"and"ricker"are accepted.- RRS
A character string or vector of strings naming parameters of the function specified by
SR_funthat differ between wild- and hatchery-origin spawners, such that the relative reproductive success of hatchery spawners is not equal to 1. Ifpool_pops == TRUE, these should be the names of the population-specific parameters, not their hyper-means. For example, iflife_cycle %in% c("SS","SSiter"), the options are"none"(the default),"alpha","Rmax", orc("alpha","Rmax"). CurrentlyRRSis only implemented forpool_pops == FALSE.- par_models
Optional list of two-sided formulas of the form
theta ~ x1 + ... + xK, wherethetais a (hyper)parameter or state in the model specified bystan_modelthat accepts covariates (see Details for available model-parameter combinations) andx1 + ... + xKare terms involving variables infish_data. Standard formula syntax such as:and*may be used; seestats::formula().- include
Logical scalar defaulting to
TRUEindicating whether to include or exclude the parameters given bypars.- log_lik
Logical scalar indicating whether the pointwise log-likelihood should be saved, e.g. for later use with
loo::loo().