Calculate error of stratified estimates
strat_error(sim)
Object returned by run_strat()
, which includes the simulated population,
survey results, and stratified analysis outputs.
Adds error details and summary statistics to the sim
list, ending with
"*_strat_error"
and "*_strat_error_stats"
. Error statistics include:
MAE: Mean absolute error
MSE: Mean squared error
RMSE: Root mean squared error
# \donttest{
sim <- sim_abundance(ages = 1:5, years = 1:5,
R = sim_R(log_mean = log(1e+7)),
growth = sim_vonB(length_group = 1)) |>
sim_distribution(grid = make_grid(res = c(20, 20)),
ays_covar = sim_ays_covar(sd = 1)) |>
sim_survey(n_sims = 1, q = sim_logistic(k = 2, x0 = 3)) |>
run_strat() |>
strat_error()
# }