check_mapper_input_colnames() is superseded by function_map(),
whose mappers check their input columns themselves.
Call it in a handwritten mapper. It errors if data lacks a key column, or
if it already has a column named like the key result column
("consistency" by default).
check_mapper_input_colnames(
data,
reported,
name_test,
name_key_result = "consistency"
)No return value; might throw an error.
Data frame. Input to the mapper.
String. Names of the key columns that data must have,
such as c("x", "n") for grim_map().
String (length 1). Plain-text name of the test, such as
"GRIM", for the error message.
String (length 1). Name of the result column that
the mapper adds. Default is "consistency".
vignette("consistency-tests-in-depth").