.checkColumnValues checks if a single column in a data frame contains valid values according to the extdata/curation_template.tsv file.

.checkColumnValues(dat, col, dat_name = NULL, quiet_success = TRUE)

Arguments

dat

A data frame imported through the bugphyzz functions.

col

A character string indicating the name of the column.

dat_name

A character string indicating the name of the dataset. Default is NULL.

quiet_success

If FALSE, an error message is printed when no errors are found. Default is TRUE.

Value

An error condition of subclass "invalid_column_values". If quiet_success is FALSE and no errors were found, it returns NULL and prints a message indicating that no errors were found.

Examples


if (FALSE) {

x <- physiologies("aerophilicity")[[1]]
err <- tryCatch(
    error = function(e) e,
    bugphyzz:::.checkColumnValues(x, "Taxon_name")
)

}