fredr_series_vintagedates: Get the data vintage dates for a FRED series

Description Usage Arguments Value API Documentation See Also Examples

View source: R/fredr_series_vintagedates.R

Description

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.

Usage

1
2
3
4
5
6
7
8
9
fredr_series_vintagedates(
  series_id,
  ...,
  limit = NULL,
  offset = NULL,
  sort_order = NULL,
  realtime_start = NULL,
  realtime_end = NULL
)

Arguments

series_id

A string ID for the FRED series.

...

These dots only exist for future extensions and should be empty.

limit

An integer limit on the maximum number of results to return. Defaults to 1000, the maximum.

offset

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.

sort_order

A string representing the order of the resulting series. Possible values are: "asc" (default), and "desc".

realtime_start

A Date indicating the start of the real-time period. Defaults to today's date. For more information, see Real-Time Periods.

realtime_end

A Date indicating the end of the real-time period. Defaults to today's date. For more information, see Real-Time Periods.

Value

A tibble object where each row is a distinct vintage date.

API Documentation

fred/series/vintagedates

See Also

fredr_series_observations(), fredr_series_search_text(), fredr_series_search_id(), fredr_series_search_tags(), fredr_series_search_related_tags(), fredr_series(), fredr_series_release(), fredr_series_tags(), fredr_series_categories(), fredr_series_updates().

Examples

1
2
3
4
5
6
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")
}

Example output



fredr documentation built on Jan. 30, 2021, 1:06 a.m.