R/fredr_series_vintagedates.R
fredr_series_vintagedates.Rd
Given a series ID, return a sequence of dates in history when a series'
data values were revised or new data values were released as a tibble
object.
fredr_series_vintagedates(
series_id,
...,
limit = NULL,
offset = NULL,
sort_order = NULL,
realtime_start = NULL,
realtime_end = NULL
)
A string ID for the FRED series.
These dots only exist for future extensions and should be empty.
An integer limit on the maximum number of results to return.
Defaults to 1000
, the maximum.
An integer used in conjunction with limit
for long series.
This mimics the idea of pagination to retrieve large amounts of data over
multiple calls. Defaults to 0
.
A string representing the order of the resulting series.
Possible values are: "asc"
(default), and "desc"
.
A Date
indicating the start of the real-time period.
Defaults to today's date. For more information, see
Real-Time Periods.
A Date
indicating the end of the real-time period.
Defaults to today's date. For more information, see
Real-Time Periods.
A tibble
object where each row is a distinct vintage date.
if (fredr_has_key()) {
# All data vintages for the "UNRATE" series
fredr_series_vintagedates(series_id = "UNRATE")
# 10 most recent data vintages for the "UNRATE" series
fredr_series_vintagedates(series_id = "UNRATE", limit = 10L, sort_order = "desc")
}
#> # A tibble: 10 × 1
#> vintage_dates
#> <chr>
#> 1 2023-04-07
#> 2 2023-03-10
#> 3 2023-02-03
#> 4 2023-01-06
#> 5 2022-12-02
#> 6 2022-11-04
#> 7 2022-10-07
#> 8 2022-09-02
#> 9 2022-08-05
#> 10 2022-07-08