Skip to contents

Validates the date column in the provided data frame. It ensures the dates are in a recognized format or a set of allowed tokens indicating the date is unknown.

Usage

validate_dates_with_tokens(data, date_col, allowed_date_formats, tokens)

Arguments

data

A data frame.

date_col

The name of the date column.

allowed_date_formats

A character vector of allowed date formats.

tokens

Recognized tokens indicating unknown dates.

Value

A list with elements error_data (an ErrorData object or NULL if no errors), parsed_dates (a vector of parsed dates), and token_mask (a logical mask identifying rows with recognized tokens indicating unknown dates).