covert_raw_to_risk.Rd
This function converts raw outcome data to risk metrics based on population data and model cases sample mean.
covert_raw_to_risk(object, outcomes_raw, model_cases_sample_mean)
A data frame with calculated risk metrics for each age group and outcome.
The function performs the following steps:
Extracts population and age group data from the input object.
Defines helper functions to check the completeness of data and calculate risk per infection.
Checks that each outcome has data for all age groups.
Combines raw outcomes data with model cases data and population data.
Calculates the risk per infection for each outcome and age group.
if (FALSE) { # \dontrun{
result <- covert_raw_to_risk(object, outcomes_raw, model_cases_sample_mean)
print(result)
} # }