rExp: run a pure-exponential sim; uses run_sim_range with a...

View source: R/kfuns.R

rExpR Documentation

run a pure-exponential sim; uses run_sim_range with a population of 1 (proportions) and a very small starting value, run for 100 steps (by default) used to calculate either r (technically r0) or eigenvector (for distributing initial exposed across states)

Description

run a pure-exponential sim; uses run_sim_range with a population of 1 (proportions) and a very small starting value, run for 100 steps (by default) used to calculate either r (technically r0) or eigenvector (for distributing initial exposed across states)

Usage

rExp(
  params,
  steps = getOption("MP_rexp_steps_default"),
  ndt = 1,
  do_hazard = FALSE,
  state = NULL,
  testify = has_testing(params = params),
  return_val = c("r0", "eigenvector", "sim"),
  type = "ICU1"
)

Arguments

params

parameters

steps

number of steps to run

ndt

sub-time steps

do_hazard

run with hazard

state

initial state as created by make_state. Leave as NULL to create state from params (??)

testify

testing compartments

return_val

return growth rate or eigenvector?

type

model type (passed to make_state)

See Also

Other classic_macpan: add_d_log(), add_updated_vaxrate(), aggregate_agecats(), 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, 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()

Examples

pp <- read_params("PHAC_testify.csv")
rExp(pp)
rExp(pp,return_val="eigenvector")
rExp(pp,return_val="eigenvector",testify=TRUE)

bbolker/McMasterPandemic documentation built on Aug. 25, 2024, 6:35 p.m.