R/fredr_series_search_tags.R
fredr_series_search_tags.Rd
Return the FRED tags by searching for matches in series text.
fredr_series_search_tags(
series_search_text,
...,
tag_names = NULL,
tag_group_id = NULL,
tag_search_text = NULL,
limit = NULL,
offset = NULL,
order_by = NULL,
sort_order = NULL,
realtime_start = NULL,
realtime_end = NULL
)
A string containing the series search text.
These dots only exist for future extensions and should be empty.
A semicolon delimited string of tag names to return. Defaults no filtering by tag names.
A string indicating the tag group id to filter tags by type. Defaults to no filtering by tag group. Possible values are
"freq"
= Frequency
"gen"
= General or Concept
"geo"
= Geography
"geot"
= Geography Type
"rls"
= Release
"seas"
= Seasonal Adjustment
"src"
= Source
A string to match tag names. Defaults to no filtering by tag name matching.
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 indicating the attribute to order results by.
Defaults to "series_count"
. Possible values are:
"series_count"
"popularity"
"created"
"name"
"group_id"
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 represents a series tag matching the
query. Data include the tag name, group ID, tag creation date, popularity,
series count, and additional notes.
if (fredr_has_key()) {
# Search for tags matching the series text "gnp"
fredr_series_search_tags("gnp")
# Search for tags matching the series text "oil" and the tag text "usa"
fredr_series_search_tags(
series_search_text = "oil",
tag_search_text = "usa"
)
# Search for tags matching the series text "oil" and the tag text "usa".
# Return only results in the "geo" (Geography) group
fredr_series_search_tags(
series_search_text = "oil",
tag_group_id = "geo",
tag_search_text = "usa"
)
}
#> # A tibble: 1 × 6
#> name group_id notes created popularity series_count
#> <chr> <chr> <chr> <chr> <int> <int>
#> 1 usa geo United States of America 2012-02-27 10… 100 5384