
Prepare country-prioritization source data
prepare_GSAP_ctry_prioritization_data.RdPulls the existing sirfunctions KPI calculations needed for the first
country-prioritization stage. This function does not download POLIS data;
the caller supplies the in-memory result of get_all_polio_data(). It also
keeps the positives data available for the later virus-risk step and reads
the long-format WUENIC workbook supplied outside POLIS.
Usage
prepare_GSAP_ctry_prioritization_data(
raw_data,
start_date,
end_date,
immunity_data = NULL,
immunity_file = NULL,
wuenic_year = NULL,
risk_table = NULL,
lab_locs = NULL,
ctry_sf = NULL,
lab_data = NULL
)Arguments
- raw_data
listOutput ofget_all_polio_data().- start_date
Dateor date-like string. Start of the analysis period.- end_date
Dateor date-like string. End of the analysis period.- immunity_data
tibbleOptional already-read WUENIC data.- immunity_file
strOptional WUENIC workbook path. Used whenimmunity_dataisNULL.- wuenic_year
integerOptional WUENIC year to use whenimmunity_datais read fromimmunity_file. IfNULL, the reader uses its default year-selection behavior.- risk_table
tibbleOptional current country-risk table. Defaults to the EDAVCTRY_RISK_CATtable.- lab_locs
tibbleOptional laboratory-location table. Defaults to the EDAV laboratory-location data.- ctry_sf
Optional country spatial layer. Defaults to
raw_data$global.ctrywhen present.- lab_data
tibbleOptional cleaned laboratory data containingDateStoolReceivedinLab. When supplied, this date is used for the C2 onset-to-laboratory timeliness indicator.