parse_iso8601_helpers: Inspecting and manipulating intermediate iso8601 matrices

parse_iso8601_helpersR Documentation

Inspecting and manipulating intermediate iso8601 matrices

Description

An "iso8601 matrix" is a matrix of the various capture groups extraced from a an iso8601 datetime string. These groups represent a superset of the fields used by partial time objects, including representation for less common datetime formats like yeardays, yearweeks or weekdays. Because the standard provides a number of different combinations of fields that represent valid strings, these functions serves to provide convenience functions for testing or manipulating these less canonical representations.

Usage

is_iso8601_form(x, fields)

is_iso8601_weekday(x)

is_iso8601_yearday(x)

is_iso8601_minfrac(x)

recalc_md_from_weekday(x)

recalc_md_from_yearday(x)

recalc_sec_from_minfrac(x)

Arguments

x

A numeric matrix of possible iso8601 fields

fields

A character vector of fields

is_iso8601_* functions

Test whether rows of the matrix represent a specific form, as evident by non-missing values in specific fields.

recalc_* functions

Calculate canonical datetime fields from alternative representations


parttime documentation built on May 29, 2024, 6:25 a.m.