Prepare a TMB Objective Function for Optimising Model Parameters
Source:R/update_params.R
update_params.RdThis function returns a list with the data to be passed to the TMB objective function. The data includes the observed catch data, the model parameters, and some precomputed values that are used in the likelihood calculation. The main preprocessing makes sure that we have a comprehensive set of bins that cover the entire size range, even though there will not be observations at all sizes. Missing observations should be interpreted as a 0 count.
Arguments
- params
A MizerParams object
- species
The species for which to update parameters. By default the first species in the model.
- pars
A named list of parameter values as returned by the TMB optimiser, containing entries for gear selectivity and mortality parameters.
- data
The data list as returned by
prepare_data().