laus_download: Download data from the Local Area Unemployment Statistics...

Description Usage Arguments Details Value Examples

View source: R/laus.R

Description

laus_download retrieves and downloads data from the Local Area Unemployment Statistics (LAUS) database.

Usage

1
2
3
4
5
6
7
8
9
laus_download(
  bls_key,
  start_year,
  end_year,
  adjustment,
  states,
  data_types,
  clean = TRUE
)

Arguments

bls_key

BLS API key for the user. See vignette.

start_year

Year to start data download.

end_year

Year to end data download.

adjustment

Character vector. Seasonal adjustment ("S") or not ("U") or both.

states

Character vector. See vignette and laus_codes_list object.

data_types

Character vector. See vignette and laus_codes_list object.

clean

Optional logical. Whether to clean the data into usable format or not. Defaults to TRUE.

Details

This function constructs BLS series IDs for a chosen set of parameters and then downloads the data from the LAUS database. This function also cleans the data and appends on identifiers for easy panel formatting.

Value

Cleaned data frame of LAUS data.

Examples

1
2
laus_download(bls_key = "inputs", start_year = 2010, end_year = 2015,
adjustment = "U", states = c("ST0100000000000", "ST0200000000000"), data_types = c("03"))

davidsovich/blsr documentation built on March 23, 2021, 5:31 a.m.