fred: Download Federal Reserve Data

Description Usage Arguments Value Examples

Description

fred downloads data from the Federal Reserve Economic Database (FRED).

Usage

1
fred(..., names = NULL, rm = TRUE, log = NULL, as_xts = FALSE)

Arguments

...

vector of FRED codes as character strings (use quotations).

names

vector of characters to replace column names in final dataframe. The length must be equal to the number of codes.

rm

logical value expressing whether or not to remove time periods that contain an NA value. Defaults to TRUE.

log

character vector describing which variables to transform using the natural logarithm.

as_xts

logical value describing whether the output should be 'xts' type.

Value

dataframe

Examples

1
2
y <- fred('GDP')
macro <- fred('GDP', 'CPIAUCSL', 'UNRATE', names = c('y', 'pi', 'u'))

cmann3/econ311 documentation built on May 31, 2019, 1:14 p.m.