Skip to contents

The companion to plida_dataset_years(): one row per dataset acronym in the bundled registry, with the period as the metadata writes it and as the generators read it. Use it to see why a build dropped a year.

Usage

plida_dataset_periods(dataset = NULL)

Arguments

dataset

Character, or NULL for every dataset. Named as the registry writes it ("TVA") or as build_fplida() names the product ("tva"), the same as plida_dataset_years(). A name the registry does not carry gives no rows, which is the table's way of saying what plida_dataset_years() says with NULL: no declared period, so nothing restricts it.

Value

A data frame with one row per dataset: dataset, the reference_period text from the registry, the parsed years in compact form, first_year, last_year and n_years.

See also

plida_dataset_years() for one dataset's years.

Examples

plida_dataset_periods("TVA")
#>   dataset reference_period     years first_year last_year n_years
#> 1     TVA     2015 to 2023 2015-2023       2015      2023       9
periods <- plida_dataset_periods()
periods[periods$dataset %in% c("TVA", "HE", "PIT_PS"), ]
#>    dataset       reference_period     years first_year last_year n_years
#> 19      HE           2005 to 2021 2005-2021       2005      2021      17
#> 34  PIT_PS 2001-2002 to 2022-2023 2002-2023       2002      2023      22
#> 42     TVA           2015 to 2023 2015-2023       2015      2023       9