View source: R/plot_exchange_rate.R
| plot_exchange_rate | R Documentation |
Generates a time series plot of the USD/BRL exchange rate using data from get_exchange_rate().
Shows the commercial exchange rate for US Dollar to Brazilian Real.
plot_exchange_rate(data, language = "eng")
data |
Tibble returned by |
language |
Language for titles and labels: "pt" (Portuguese) or "eng" (English). |
A ggplot2 object showing the exchange rate over time.
# Example 1: English version
exchange_data <- get_exchange_rate("2023-01-01", "2023-12-31")
exchange_plot <- plot_exchange_rate(exchange_data)
print(exchange_plot)
# Example 2: Portuguese version
dados_cambio <- get_exchange_rate("2023-01-01", "2023-12-31", language = "pt")
grafico_cambio <- plot_exchange_rate(dados_cambio, language = "pt")
print(grafico_cambio)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.