A function that takes a vector of ages or age groups (either numeric or factor) and returns assigned age categories based on desired lower bin edges provided by the user.
aggregate_agecats(age, bin_edges_lower)Numeric or factor vector of ages
list of numeric values for the lower edges of desired age group bins in panel 2. If ages are of type factor, all user-specified lower bin edges must match lower bin edges in the age data.
Other classic_macpan:
add_d_log(),
add_updated_vaxrate(),
calibrate_comb(),
calibrate(),
check_age_cat_compatibility(),
check_contact_rate_setting(),
col_multiply(),
condense_age(),
condense_params_vax(),
condense_state(),
condense_vax(),
dev_is_tikz(),
do_step(),
expand_params_age(),
expand_params_desc_age(),
expand_params_desc_variant(),
expand_params_desc_vax(),
expand_params_mistry(),
expand_params_variant(),
expand_params_vax(),
expand_state_age(),
expand_state_vax(),
expand_stateval_testing(),
fix_pars(),
fix_stored(),
forecast_ensemble(),
forecast_sim(),
getData(),
get_GI_moments(),
get_Gbar(),
get_R0(),
get_doses_per_day(),
get_evec(),
get_kernel_moments(),
get_opt_pars(),
get_r(),
invlink_trans(),
make_betavec(),
make_beta(),
make_jac(),
make_ratemat(),
make_state(),
make_test_wtsvec(),
make_vaxrate(),
mk_Nvec(),
mk_agecats(),
mk_contact_rate_setting(),
mk_mistry_Nvec(),
mk_pmat(),
mk_vaxcats(),
mle_fun(),
non_expanded_states,
rExp(),
read_params(),
repair_names_age(),
restore(),
run_sim_ageify(),
run_sim_break(),
run_sim_loglin(),
run_sim_mobility(),
run_sim_range(),
run_sim(),
show_ratemat(),
testify(),
texify(),
trans_state_vars(),
update_contact_rate_setting(),
update_foi(),
update_params_mistry(),
vis_model(),
write_params()
aggregate_agecats(seq(0, 90, by = 1), c(25, 45))
#> [1] 0-24 0-24 0-24 0-24 0-24 0-24 0-24 0-24 0-24 0-24 0-24 0-24
#> [13] 0-24 0-24 0-24 0-24 0-24 0-24 0-24 0-24 0-24 0-24 0-24 0-24
#> [25] 0-24 25-44 25-44 25-44 25-44 25-44 25-44 25-44 25-44 25-44 25-44 25-44
#> [37] 25-44 25-44 25-44 25-44 25-44 25-44 25-44 25-44 25-44 45+ 45+ 45+
#> [49] 45+ 45+ 45+ 45+ 45+ 45+ 45+ 45+ 45+ 45+ 45+ 45+
#> [61] 45+ 45+ 45+ 45+ 45+ 45+ 45+ 45+ 45+ 45+ 45+ 45+
#> [73] 45+ 45+ 45+ 45+ 45+ 45+ 45+ 45+ 45+ 45+ 45+ 45+
#> [85] 45+ 45+ 45+ 45+ 45+ 45+ 45+
#> Levels: 0-24 25-44 45+