Skip to contents

Add SBT model priors

Usage

sbt_add_priors(fit, priors = NULL)

Arguments

fit

An sbt_fit() object.

priors

Optional named prior list compatible with get_priors(). If omitted, the package defaults are resolved from the fit parameters.

Value

The updated sbt_fit, with the resolved prior specification stored in fit$data$priors.

Examples

fit <- sbt_fit(sbt_example_data())
fit <- sbt_add_priors(fit)
names(fit$data$priors)
#>  [1] "par_log_psi"        "par_log_m10"        "par_log_m30"       
#>  [4] "par_mc"             "par_log_h"          "par_log_cpue_omega"
#>  [7] "par_log_sigma_r"    "par_cpue_creep"     "par_sel_rho_y"     
#> [10] "par_sel_rho_a"      "par_log_sel_sigma"