add_economics-RSVProgramme-method.Rd
This method adds economic data to an RSVProgramme object.
# S4 method for class 'RSVProgramme'
add_economics(object, econ_name, econ_raw, risks_raw, risks_vhr_raw)
The updated RSVProgramme
object with the added economic data.
This method performs the following steps:
Checks if the output directory for the economic data exists, and creates it if it does not.
Assigns the provided economic data and risk data to the corresponding slots in the RSVProgramme
object.
Extracts unique outcomes from the economic data and assigns them to the outcomes_vec
slot.
Stops execution if no outcomes are detected in the economic data.
Generates samples of outcomes and assigns them to the samples_outcomes
and samples_outcomes_VHR
slots.
if (FALSE) { # \dontrun{
rsv_programme <- new("RSVProgramme")
rsv_programme <- add_economics(rsv_programme, "econ_data", econ_raw_df, risks_raw_df, risks_vhr_raw_df)
} # }