require_column: Require a column exists in a data frame
Description
Simple check that a single column exists. For checking multiple columns,
use validate_dataframe() with required_cols parameter.
Usage
require_column(df, col, param_name = deparse(substitute(df)))
Value
Invisible TRUE if column exists, otherwise stops with error
Arguments
- df
Data frame to check
- col
Column name to require
- param_name
Name of the data frame parameter (for error message)