Introduction#
evdspy is an open-source Python interface that simplifies making requests to the Central Bank of the Republic of Turkey (CBRT) Economic Data Service (EDS). It provides efficient request handling by caching results, a user-friendly menu for data inquiries, and capabilities for handling complex data structures through an accessible API.
View Source Code#
You can view the source code for this project on GitHub: View Source.
What’s New#
Updated on this version:
- The API key parameter has now been moved to the HTTP header to enhance security and ensure that sensitive information is not exposed in URLs.
- Added a new function, get_series, which enhances the way data groups and series are handled.
- Deprecated: The get_datagroup function will be deprecated in future versions; get_series will cover its functionalities.
Key Features#
API Key Management: Automatically saves the API key to a file when provided to the
get_seriesfunction, ignoring subsequent entries unless explicitly updated.Visual and Textual Menu Options: Provides both a visual and textual menu to facilitate user interaction for setting up projects, creating output folders, and preparing configuration files.
Data Request Handling: Utilizes caching to optimize data retrieval, minimizing redundant requests and speeding up the data access process.
Installation#
To install evdspy, simply run the following command: .. code-block:: bash
pip install evdspy -U
Quick Start#
Here’s a quick example to get you started with using evdspy:
from evdspy import get_series, default_start_date_fnc, default_end_date_fnc
index = "TP.ODEMGZS.BDTTOPLAM", "TP.ODEMGZS.ABD"
df = get_series(index, frequency="monthly", start_date=default_start_date_fnc(), end_date=default_end_date_fnc(), aggregation=("avg",), cache=True)
print(df)
API Usage Examples#
1
2from evdspy import *
3template = """TP_GSYIH01_GY_CF
4TP_GSYIH02_GY_CF
5TP_GSYIH03_GY_CF
6TP_GSYIH04_GY_CF
7TP_GSYIH05_GY_CF
8TP_GSYIH06_GY_CF
9TP_GSYIH07_GY_CF
10TP_GSYIH08_GY_CF
11TP_GSYIH09_GY_CF
12TP_GSYIH10_GY_CF
13TP_GSYIH11_GY_CF
14TP_GSYIH14_GY_CF
15TP_GSYIH15_GY_CF
16TP_GSYIH16_GY_CF
17"""
18df = get_series(template, debug=False)
19print(df)
Learn More#
For more detailed information on all functions and their parameters, refer to the Modules section or visit our [GitHub Repository](SermetPekin/evdspy-repo).
Disclaimer#
Please note that evdspy is not officially affiliated with or endorsed by the CBRT. It is developed and maintained under an MIT license by independent developers. Use of this tool should comply with all applicable laws and API usage guidelines provided by the CBRT.