powered by
creates a quarterly date vector from a date vector
date_yq(x)
date vector
a date
seq.Date(lubridate::ymd(20200101), lubridate::ymd(20220101), length.out = 10) -> d1 d1 %>% tibble::enframe() %>% dplyr::mutate(YQ = date_yq(value))
Run the code above in your browser using DataLab