Skip to contents

These functions provide methods to load metadata associated with a template and the arguments used to a specific download.

Usage

template_meta_load(template, ...)

Arguments

template

An object representing the template. Can be of class character (template ID) or template (template object).

...

Additional arguments used in a specific download.

Value

The metadata associated with the download.

Details

The download_marketdata() function returns a meta object that refers to a specific download. If the meta object does not exist, it is created. If the specific download has already been performed in the past, a meta file will exist, and download_marketdata() will raise an error upon detecting it. In such cases, the template_meta_load() function should be used to load the meta object associated with the existing meta file.

Examples

# Example usage with a template ID
m <- tryCatch(download_marketdata("b3-indexes-composition"), error = function(e) {
  template_meta_load("b3-indexes-composition")
})
read_marketdata(m)