country_letters: Create PDF letters with feedback for countries. Returns an...

Description Usage Arguments See Also

View source: R/letters.R

Description

Create PDF letters with feedback for countries. Returns an PDF document for each country with summary counts of issues flagged. Requires WHO IDSR data which has been prepared using the clean_idsr function, and then run through the missing_checker and threshold_checker functions, and all being stored in a list with a data frame for each country.

Usage

1
2
3
4
5
6
7
country_letters(
  x,
  flags = flags,
  current_year = 2020,
  current_week = 1,
  output_path = here::here("Data Files", "Output")
)

Arguments

x

A list of data frames which has been processed with clean_idsr, missing_checker and threshold_checker.

flags

A list including missings and alert flags for each country, produced by country_feedback

current_year

The year of interest as numeric (e.g. the default is 2020)

current_week

The week of interest as numeric. The default is 1. Values less than 10 are padded with leading zeros, e.g. 1 becomes 01. (You could also enter 01 and it would be fine)

output_path

File path where you would like outputs to be saved to. Within this folder a new folder will be created for the current year, and within that the current week. This defaults to your current directory, with subfolders of Data Files > Output > 2020 > 01. The year folder needs to exist already - only the current week folder will be created.

See Also

clean_idsr for preparing IDSR data for use with threshold_checker, missing_checker for missing flags and threshold_checker for threshold flags.


R4IDSR/epichecks documentation built on Sept. 18, 2021, 2:03 p.m.