Collects every window, distance, threshold, vaccine list, status list and
verdict label that calc_es_scorecard(), calc_es_score_network() and
calc_es_score_profile() use. The defaults are the programme standards the
Afghanistan weekly review applies today.
Usage
es_score_settings(
opv_types = c("bOPV", "tOPV", "mOPV1", "mOPV3", "mOPV2", "IPV + bOPV"),
campaign_statuses = c("Done", "Confirmed"),
peak_weeks = 4,
mid_weeks = c(6, 12),
floor_weeks = 24,
neighbour_km = 20,
window_days = 62,
active_months = 12,
min_n = 5,
floor_pct = 30,
trend_years = 3,
trend_min_n = 5,
new_site_months = 12,
trend_drop_pts = 15,
trend_alpha = 0.05,
isolation_min_samples = 5,
isolation_min_pct = 50,
verdict_labels = c(below_floor = "Below the floor", falling = "Falling", low_isolation
= "Low isolation", working = "Working", unjudged = "Too few samples"),
profile_breaks = c(-1, 2, 4, 6, 8, 12, 24, 52, Inf),
profile_labels = c("0-2w", "2-4w", "4-6w", "6-8w", "8-12w", "12-24w", "24-52w", ">1y"),
days_per_month = 30.44,
crs = "+proj=laea +lat_0=31 +lon_0=68 +datum=WGS84 +units=m +no_defs"
)Arguments
- opv_types
Campaign vaccine types that shed Sabin virus. A campaign counts only when its vaccine type is one of these. Default
"bOPV","tOPV","mOPV1","mOPV3","mOPV2"and"IPV + bOPV".- campaign_statuses
Campaign statuses that count as a campaign that took place. Default
"Done"and"Confirmed".- peak_weeks
Weeks after the start of the latest campaign in the site's own district within which a sample counts towards campaign response. The window includes both ends, from week 0 to this value. Default
4.- mid_weeks
Two numbers giving the retention window in weeks after a campaign. A sample counts when its weeks since the campaign are above the first value and at most the second. Default
c(6, 12).- floor_weeks
Weeks after a campaign beyond which a sample counts towards the between-campaign background level. Default
24.- neighbour_km
Largest distance in kilometres between two sites for one to count as the other's neighbour. Default
20.- window_days
Largest gap in days between the month a site was sampled and the month a neighbour recovered virus for the two to count as the same occasion. Months are compared by their first day. Default
62.- active_months
A site is judged only if its last sample falls within this many months of the latest sample in the network. Default
12.- min_n
Fewest samples or occasions a measure needs. Below it the site is not given a verdict, and the measure is left out of the network rate. Default
5.- floor_pct
The detection floor: the campaign response percentage below which a site is judged below the floor. Default
30.- trend_years
Years before the latest sample at which a site's record is split into an earlier and a recent part. Default
3.- trend_min_n
Fewest campaign response samples each part needs before the two parts are compared. Default
5.- new_site_months
For a site whose first sample falls after the split, the recent part is instead its last this many months. Default
12.- trend_drop_pts
Smallest fall in percentage points from the earlier to the recent part that counts as a decline. Default
15.- trend_alpha
Significance level of the Fisher's exact test that a decline must also pass. Default
0.05.- isolation_min_samples
Fewest samples with a final result a site needs before its enterovirus isolation is judged. Default
5.- isolation_min_pct
Enterovirus isolation percentage below which a site is judged to have low isolation. Default
50.- verdict_labels
Named character vector of the five verdict labels, with names
below_floor,falling,low_isolation,workingandunjudged. The first four are listed worst first and set the order of the verdict factor;unjudgedcomes last.- profile_breaks, profile_labels
Bands of weeks since a campaign used by
calc_es_score_profile(), passed tocut()with intervals closed on the right. Default bands are 0 to 2, 2 to 4, 4 to 6, 6 to 8, 8 to 12, 12 to 24 and 24 to 52 weeks, and more than a year.- days_per_month
Days used to convert a gap in days into months. Default
30.44.- crs
Projection used to measure the distance between sites, as a PROJ string or EPSG code. The default is a Lambert azimuthal equal-area projection centred on Afghanistan and Pakistan, so a kilometre means the same across that network.
Examples
es_score_settings(neighbour_km = 25)
#> $opv_types
#> [1] "bOPV" "tOPV" "mOPV1" "mOPV3" "mOPV2"
#> [6] "IPV + bOPV"
#>
#> $campaign_statuses
#> [1] "Done" "Confirmed"
#>
#> $mid_weeks
#> [1] 6 12
#>
#> $trend_alpha
#> [1] 0.05
#>
#> $verdict_labels
#> below_floor falling low_isolation working
#> "Below the floor" "Falling" "Low isolation" "Working"
#> unjudged
#> "Too few samples"
#>
#> $profile_breaks
#> [1] -1 2 4 6 8 12 24 52 Inf
#>
#> $profile_labels
#> [1] "0-2w" "2-4w" "4-6w" "6-8w" "8-12w" "12-24w" "24-52w" ">1y"
#>
#> $crs
#> [1] "+proj=laea +lat_0=31 +lon_0=68 +datum=WGS84 +units=m +no_defs"
#>
#> $peak_weeks
#> [1] 4
#>
#> $floor_weeks
#> [1] 24
#>
#> $neighbour_km
#> [1] 25
#>
#> $window_days
#> [1] 62
#>
#> $active_months
#> [1] 12
#>
#> $min_n
#> [1] 5
#>
#> $floor_pct
#> [1] 30
#>
#> $trend_years
#> [1] 3
#>
#> $trend_min_n
#> [1] 5
#>
#> $new_site_months
#> [1] 12
#>
#> $trend_drop_pts
#> [1] 15
#>
#> $isolation_min_samples
#> [1] 5
#>
#> $isolation_min_pct
#> [1] 50
#>
#> $days_per_month
#> [1] 30.44
#>
#> attr(,"class")
#> [1] "es_score_settings"
