MizerSim rate getter that resolves the rate functions onceInternal helper capturing the pattern shared by the MizerSim rate getters
that return a species-by-size array. It validates the params and resolves the
rate functions a single time, then for each saved time step calculates only
the required target rate with mizer_rates_subset() and extracts the
element named slot from the result.
sim_size_rate(
sim,
time_range,
drop,
target,
slot,
value_name,
units = NULL,
use_sim_effort = FALSE,
...
)An ArrayTimeBySpeciesBySize object (or a reduced array if drop).
A MizerSim object.
Passed to the sim iteration helper.
Passed to the sim iteration helper.
Name of the rate to calculate (as in params@rates_funcs).
Name of the element to extract from the mizer_rates_subset()
result (e.g. "e_growth" for the EGrowth rate).
Metadata for the returned array.
If TRUE, the saved effort at each time step is used;
otherwise the initial effort is used (matching the behaviour of the
corresponding MizerParams getter).
Passed on to the rate functions.