Prep Data for Box plot
iidda_prep_box.Rd
Prep data for plotting box plots. Prep steps were taken from `LBoM::monthly_box_plot` and they include handling missing values and creating additional time unit fields.
Usage
iidda_prep_box(
data,
series_variable = "deaths",
time_variable = "period_end_date",
time_unit = "week",
handle_missing_values = HandleMissingValues(na_remove = FALSE, na_replace = NULL),
handle_zero_values = HandleZeroValues(zero_remove = FALSE, zero_replace = NULL)
)
Arguments
- data
data frame containing time series data
- series_variable
column name of series variable in `data`, default is "deaths"
- time_variable
column name of time variable in `data`, default is "period_end_date"
- time_unit
time unit to create field from `time_variable`. Must be one of iidda.analysis:::time_units, defaults to "week".
- handle_missing_values
function to handle missing values, defaults to HandleMissingValues
- handle_zero_values
function to handle zero values, defaults to HandleZeroValues