| boc_data | R Documentation |
Retrieve time series data from the Bank of Canada Valet API.
boc_data(
group_name = NULL,
series_name = NULL,
start_date = NULL,
end_date = NULL
)
group_name |
( |
series_name |
( |
start_date |
( |
end_date |
( |
A data.table::data.table() with the requested data.
https://www.bankofcanada.ca/valet/docs
Other data:
bbk_data(),
bbk_series(),
bde_data(),
bdf_codelist(),
bdf_data(),
bdf_dataset(),
boe_data(),
ecb_data(),
onb_data(),
snb_data()
## Not run:
# fetch all data for a single group
dt <- boc_data(group_name = "FX_RATES_DAILY")
head(dt)
# or for multiple series ids
dt <- boc_data(
series_name = c("FXUSDCAD", "FXEURCAD"),
start_date = "2023-01-23",
end_date = "2023-07-19"
)
head(dt)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.