Title: | CBRT Data on Turkish Economy |
---|---|
Description: | The Central Bank of the Republic of Turkey (CBRT) provides one of the most comprehensive time series databases on the Turkish economy. The 'CBRT' package provides functions for accessing the CBRT's electronic data delivery system <https://evds2.tcmb.gov.tr/>. It contains the lists of all data categories and data groups for searching the available variables (data series). As of November 3, 2024, there were 40,826 variables in the dataset. The lists of data categories and data groups can be updated by the user at any time. A specific variable, a group of variables, or all variables in a data group can be downloaded at different frequencies using a variety of aggregation methods. |
Authors: | Erol Taymaz [aut, cre] |
Maintainer: | Erol Taymaz <[email protected]> |
License: | GPL-3 |
Version: | 0.1.1 |
Built: | 2024-11-14 04:34:41 UTC |
Source: | https://github.com/etaymaz/cbrt |
A dataset containing the list of all data categories in the CBRT dataset
allCBRTCategories
allCBRTCategories
A data table with 23 rows and 2 variables:
Category ID
Topic
A dataset containing the list of all data groups in the CBRT dataset
allCBRTGroups
allCBRTGroups
A data table with 323 rows and 10 variables:
Category ID
Data group code (used for downloading the data)
Name of the data group
Time series frequency code
Data source
URL of the data source
Revision policy for the data group
The beginning date for the data
The end date for the data
URL
A dataset containing the list of all data series in the CBRT dataset
allCBRTSeries
allCBRTSeries
A data table frame with 22,243 rows and 12 variables:
Category ID
Topic
Data group code
Name of the data group
Time series frequency code
Data series code (used for downloading the data)
Name of the data series
Starting date, DD-MM-YYYY
Ending date, DD-MM-YYYY
Data aggregation method
Time series frequency
Tages (keywords)
A dataset containing the list of aggregation methods
CBRTagg
CBRTagg
A data table frame with 6 rows and 2 variables:
Aggregation code
Aggregation method
A dataset containing the list of frequencies
CBRTfreq
CBRTfreq
A data table frame with 8 rows and 4 variables:
Frequency code
Frequency code (internal use)
Frequency name (English)
Frequency name (Turkish)
Creates a meta data object for all categories
getAllCategoriesInfo(CBRTKey = myCBRTKey)
getAllCategoriesInfo(CBRTKey = myCBRTKey)
CBRTKey |
Your personal CBRT access key |
a data.table object
## Not run: allCBRTCategories <- getAllCategoriesInfo() ## End(Not run)
## Not run: allCBRTCategories <- getAllCategoriesInfo() ## End(Not run)
Creates a meta data object for all data gorups
getAllGroupsInfo(CBRTKey = myCBRTKey)
getAllGroupsInfo(CBRTKey = myCBRTKey)
CBRTKey |
Your personal CBRT access key |
a data.table object
## Not run: allCBRTGroups <- getAllGroupsInfo() ## End(Not run)
## Not run: allCBRTGroups <- getAllGroupsInfo() ## End(Not run)
Creates a meta data object for all data series
getAllSeriesInfo(CBRTKey = myCBRTKey, verbose = TRUE)
getAllSeriesInfo(CBRTKey = myCBRTKey, verbose = TRUE)
CBRTKey |
Your personal CBRT access key |
verbose |
TRUE turns on status and information messages to the console |
a data.table object
## Not run: allCBRTSeries <- getAllSeriesInfo() ## End(Not run)
## Not run: allCBRTSeries <- getAllSeriesInfo() ## End(Not run)
Downloads all data series of a data group
getDataGroup( group, CBRTKey = myCBRTKey, freq, startDate = "01-01-1950", endDate, na.rm = TRUE, verbose = TRUE )
getDataGroup( group, CBRTKey = myCBRTKey, freq, startDate = "01-01-1950", endDate, na.rm = TRUE, verbose = TRUE )
group |
Code for the data group. |
CBRTKey |
Your personal CBRT access key. |
freq |
Numeric, the frequency of the data series. If not defined, the default (the highest possible frequency) will be used. The frequencies are as follows:
If a frequency level lower than the default is used, the data will be aggregated by using the default method for that data group (for example, if monthly data are download for weekly series). |
startDate |
The beginning date for data series (DD-MM-YYYY). |
endDate |
The ending date for data series (DD-MM-YYYY). If not defined, the default (the latest available) will be used. |
na.rm |
Logical variable to drop all missing dates. |
verbose |
TRUE turns on status and information messages to the console. |
a data.table object
## Not run: myData <- getDataGroup("bie_dbafod") ## End(Not run)
## Not run: myData <- getDataGroup("bie_dbafod") ## End(Not run)
Downloads one or more data series from the CBRT datasets.
getDataSeries( series, CBRTKey = myCBRTKey, freq, aggType, startDate = "01-01-1950", endDate, na.rm = TRUE )
getDataSeries( series, CBRTKey = myCBRTKey, freq, aggType, startDate = "01-01-1950", endDate, na.rm = TRUE )
series |
A vector of data series' codes. |
CBRTKey |
Your personal CBRT access key. |
freq |
Numeric, the frequency of the data series. If not defined, the default (the highest possible frequency) will be used. The frequencies are as follows:
|
aggType |
Aggregation of data series. This paremeter defines the method to be used to aggregate data series from high frequency to low frequency (for example, weekly data to monthly data). The following methods are available:
If a frequency level lower than the default is used, the data will be aggregated by using the default method for that data group (for example, if monthly data are download for weekly series). |
startDate |
The beginning date for data series (DD-MM-YYYY). |
endDate |
The ending date for data series (DD-MM-YYYY). If not defined, the default (the latest available) will be used. |
na.rm |
Logical variable to drop all missing dates. |
a data.table object
## Not run: mySeries <- getDataSeries("TP.D1TOP") mySeries <- getDataSeries(c("TP.D1TOP", "TP.D2HAZ", "TP.D4TCMB")) mySeries <- getDataSeries(c("TP.D1TOP", "TP.D2HAZ", "TP.D4TCMB", startDate="01-01-2010")) ## End(Not run)
## Not run: mySeries <- getDataSeries("TP.D1TOP") mySeries <- getDataSeries(c("TP.D1TOP", "TP.D2HAZ", "TP.D4TCMB")) mySeries <- getDataSeries(c("TP.D1TOP", "TP.D2HAZ", "TP.D4TCMB", startDate="01-01-2010")) ## End(Not run)
Search for keywords in the CBRT datasets
searchCBRT(keywords, field = c("groups", "categories", "series"), tags = FALSE)
searchCBRT(keywords, field = c("groups", "categories", "series"), tags = FALSE)
keywords |
A vector of keywords |
field |
The name of the field to be searched ("groups", "categories" or "series"). We recommend searching first the "groups" names. |
tags |
A logical variable that indicates if the tags to be searched |
a data.table object
searchCBRT(c("production", "labor", "labour")) searchCBRT(c("production", "labor", "labour"), field = "series") searchCBRT(c("production", "labor", "labour"), tags = TRUE)
searchCBRT(c("production", "labor", "labour")) searchCBRT(c("production", "labor", "labour"), field = "series") searchCBRT(c("production", "labor", "labour"), tags = TRUE)
Shows information about a data group
showGroupInfo(gCode, verbose = TRUE)
showGroupInfo(gCode, verbose = TRUE)
gCode |
the code for the data group |
verbose |
TRUE turns on status and information messages to the console |
a data.table object
showGroupInfo("bie_apifon")
showGroupInfo("bie_apifon")
Shows the names of all variables in a data group
showSeriesNames(gCode)
showSeriesNames(gCode)
gCode |
the code for the data group |
a data.table object
showSeriesNames("bie_apifon")
showSeriesNames("bie_apifon")