Check that the input wastewater data contains all the required column names
Source:R/checkers.R
assert_req_ww_cols_present.Rd
This function is intended to be used to check that the wastewater data that
gets passed into preprocess_ww_data()
contains the required columns. If
it does not, we want to tell the user which column are missing. This will not
however, ensure that the elements of the column are of the right type,
or check that the values of them make sense.
Usage
assert_req_ww_cols_present(
ww_data,
conc_col_name,
lod_col_name,
add_req_col_names = c("date", "site", "lab", "site_pop"),
call = rlang::caller_env()
)
Arguments
- ww_data
tibble containing the input wastewater data
- conc_col_name
string indicating the name of the column containing the concentration measurements in the wastewater data
- lod_col_name
string indicating the name of the column containing the concentration measurements in the wastewater data
- add_req_col_names
vector of strings indicating the required wastewater column names, the defaults are
c("date", "site", "lab", "site_pop")
- call
Calling environment to be passed to
cli::cli_abort()
for traceback.