dot-validate_time_components: Multi-column time input path Validate time components and...

.validate_time_componentsR Documentation

Multi-column time input path Validate time components and build Date safely

Description

Multi-column time input path Validate time components and build Date safely

Usage

.validate_time_components(
  y,
  m = NULL,
  d = NULL,
  doy = NULL,
  h = NULL,
  mode = c("ymd", "ydoy"),
  time_api_resolved = c("daily", "hourly"),
  time_cols = character(),
  max_examples = 5L
)

Arguments

y, m, d

Integer-ish vectors (for mode="ymd").

doy

Integer-ish vector (for mode="ydoy").

h

Optional integer-ish vector.

mode

"ymd" or "ydoy"

time_api_resolved

"hourly" or "daily" (for hourly requirement checks)

time_cols

Character vector of user-specified columns for error context.

max_examples

How many bad examples to show in error messages.

Value

A list with date (Date) and hour (integer, possibly NA if missing and not allowed).


weatherjoin documentation built on Feb. 4, 2026, 5:11 p.m.