sgs_untidy | R Documentation |
Convert a tidy dataframe into a list of separate time series objects like 'xts' and 'ts' or even a 'tibble' with a time series representation ( two columns with dates and values).
sgs_untidy(x, tidydf, as = c("tibble", "xts", "ts"))
x |
sgs object with the corresponding codes |
tidydf |
tidy dataframe returned by 'rbcb_get' |
as |
the returning type ('tibble', 'xts', 'ts') |
a list with time series objects
## Not run:
x <- sgs(USD = 1, SELIC = 1178)
df <- rbcb_get(x, from = Sys.Date() - 10)
sgs_untidy(x, df, as = "xts")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.