wilsonfreitas / rbcb

R interface to Brazilian Central Bank web services
https://wilsonfreitas.github.io/rbcb/
Other
91 stars 22 forks source link

Set an attribute symbol for time series returned from get_currency #37

Closed wilsonfreitas closed 3 years ago

wilsonfreitas commented 3 years ago

The get_currency function returns a data.frame or xts object with bid and ask columns. This object has no reference to the original currency symbol, so it might be lost if the assignment doesn't name the variable properly. In order to correct that a new attribute containing the symbol must be set in the returned object.