confhd_data: Get data from 'CONFHD.DAT' file for the a given year and...

View source: R/newave-data.R

confhd_dataR Documentation

Get data from CONFHD.DAT file for the a given year and month

Description

Get data from CONFHD.DAT file for the a given year and month

Usage

confhd_data(
  YYYYMM = format.Date(Sys.Date() - 40, "%Y%m"),
  confhd_path = TRUE
)

Arguments

YYYYMM

character vector with year (YYYY) and month (MM). Accepted formats are for example "201809", "2018", "2018.02", "2018-03", "2018-04-01", "2018/05".

confhd_path

logical. Default: TRUE, will return the path to CONFHD.DAT file, otherwise the path to the temporary directory of extracted data.

Value

a tibble with tidy data.

Note

A data request for the current month may not yet be available for UHEs configuration data. That is why it is recommended to use the date in the previous 40 days to ensure that the data will be available.

Source

Data are available in https://www.ccee.org.br/ccee/documentos since July/2012.

Examples

if(FALSE){
# Get the table for the previous month to ensure that the data already exists
uhes_info <- confhd_data(format.Date(Sys.Date()-40, "%Y%m"))
}


lhmet-ped/HEgis documentation built on July 23, 2022, 2:59 a.m.