new_yearquarter: Minimal constructor for a yearquarter object

View source: R/yearquarter.R

new_yearquarterR Documentation

Minimal constructor for a yearquarter object

Description

new_yearquarter() is a constructor for ⁠<grates_yearquarter>⁠ objects aimed at developers.

Usage

new_yearquarter(x = integer())

is_yearquarter(xx)

Arguments

x

⁠[integer]⁠

Vector representing the number of quarters.

double vectors will be converted via as.integer(floor(x)).

xx

R object.

Details

⁠<yearquarter>⁠ objects are stored as the number of quarters (starting at 0) since the Unix Epoch (1970-01-01).

Value

A ⁠<grates_yearquarter>⁠ object.

Examples

new_yearquarter(1:10)


grates documentation built on July 9, 2023, 7:09 p.m.