Retrieve time series observations from the CNB ARAD database. ARAD is the CNB's full statistical database, covering monetary, financial-market, balance-of-payments, and government finance statistics. Access requires an API key, which can be generated from a free account at https://www.cnb.cz/arad/.
cnb_data(
indicator_id = NULL,
set_id = NULL,
base_id = NULL,
selection_id = NULL,
start_period = NULL,
end_period = NULL,
snapshot_id = NULL,
api_key = cnb_arad_key()
)A data.table::data.table() with columns:
The observation period
The indicator identifier
The snapshot identifier, or NA for non-snapshot data
The observation value
(NULL | character())
One or more indicator identifiers to retrieve (e.g. "SMV5M603"). Exactly one of
indicator_id, set_id, base_id, or selection_id must be provided.
(NULL | character(1))
A set ("sestava") identifier, returning all of its indicators.
(NULL | character(1))
A base identifier, returning all of its indicators.
(NULL | character(1))
The identifier of a named selection ("My selections") created in your ARAD account.
(NULL | character(1) | Date(1))
Start of the period to retrieve. If NULL, no start restriction is applied. Default NULL.
(NULL | character(1) | Date(1))
End of the period to retrieve, in the same format as start_period. Default NULL.
(NULL | character())
One or more snapshot ids to retrieve historical vintages, or "ALL" for every snapshot. If
NULL, the current (non-snapshot) data is returned. See cnb_snapshots(). Default NULL.
(character(1))
API key to use for the request. Defaults to the value returned by cnb_arad_key(), which reads
from the CNB_ARAD_KEY environment variable.
Other data:
bbk_data(),
bbk_series(),
bde_data(),
bde_latest(),
bdf_codelist(),
bdf_data(),
bdf_dataset(),
bdp_data(),
bis_data(),
boc_data(),
boe_data(),
boj_data(),
cnb_czeonia(),
cnb_fx_other_rates(),
cnb_fx_rates(),
cnb_pribor(),
ecb_data(),
nbp_fx_rates(),
nbp_gold(),
nob_data(),
onb_data(),
snb_data(),
srb_cross_rates(),
srb_data()
if (FALSE) {
# a single indicator over 24 months
cnb_data("SMV5M603", start_period = "2023-01-01")
# every indicator in a set
cnb_data(set_id = "1058")
}
Run the code above in your browser using DataLab