- Last update: April 2025
- Environment: Windows
- Compiler: Python
- Prerequisite: LSEG Workspace desktop application with access to Data Library.
Due to this DA (Data Notification) DN092084-Decommission of ECON chains from Workspace effective on 30 September 2017, we are moving away from the previous Country Economic Indicator chains to apps that are fully customizable and leverage on the depth of content that is available. For example, these chains have a fixed view and users cannot change which columns they want to see or don’t want to see. Whereas the Economic Monitor app on Workspace allows full customization to view the calendar of releases. For example, users can customize the following:
- List of countries
- Range of dates for events
- View only a customized set of indicators
- Alter the position of column
- Add and remove the columns
To access Economic Monitor app, Type EM in the Workspace Search box and hit Enter, to launch the app.
The Data Library for Python provides a set of ease-of-use interfaces offering coders uniform access to the breadth and depth of financial data and services available on the Workspace, RDP, and Real-Time Platforms. The API is designed to provide consistent access through multiple access channels and target both Professional Developers and Financial Coders. Developers can choose to access content from the desktop, through their deployed streaming services, or directly to the cloud. With the Data Library, the same Python code can be used to retrieve data regardless of which access point you choose to connect to the platform.
The Data Library are available in the following programming languages:
For more deep detail regarding the Data Library for Python, please refer to the following articles and tutorials:
This project is based on Data Library Python versions 2.1.1 using the Desktop Session only.
This example requires the following dependencies softwares and libraries.
- LSEG Workspace desktop application with access to Data Library for Python.
- Python (Ananconda or MiniConda distribution/package manager also compatible).
- Jupyter Lab application.
Note:
- This Project has been qualified with Python version 3.11.5
- If you are not familiar with Jupyter Lab application, the following tutorial created by DataCamp may help you.
Please follow a step by step guide to setup your library and App-Key in "Desktop - Eikon or LSEG Workspace" of LSEG Data Library for Python Quick Start page .
Please note that the Workspace desktop application integrates a Data API proxy that acts as an interface between the Python library and the Workspace Platform. For this reason, the Workspace application must be running when you use the Data library.
The first step is unzip or download the example project folder into a directory of your choice, then choose how to run application based on your environment below.
-
Open a Command Prompt and go to project's folder
-
Run the following command in a Command Prompt to create a Python virtual environment named econ for the project.
$>python -m venv econ
-
Once the environment is created, activate a virtual environment named
econ
with this command in a Command Prompt$>econ\Scripts\activate
-
Go to project's notebook folder and update a contain in
lseg-data.config.json
file with the your App-Key{ "logs": { "level": "debug", "transports": { "console": { "enabled": false }, "file": { "enabled": false, "name": "lseg-data-lib.log" } } }, "sessions": { "default": "desktop.workspace", "desktop": { "workspace": { "app-key": "YOUR APP KEY GOES HERE!" } } } }
-
Run the following command in a Command Prompt to install the project dependencies
$>(econ) pip install -r requirements.txt
-
In the current Command Prompt, go to project's notebook folder. Run the following command to start Jupyter Lab in the notebook folder.
$>(econ)>notebook>jupyter lab
-
Open ld_cross-economic-indicators.ipynb Notebook document, then follow through each notebook cell.
Note: If you are using AnaConda/MiniConda, please refer to this Conda - Managing environments document for more detail about how create and activate environment with Conda.
You can find more detail regarding the Data Library and related technologies for this Notebook from the following resources:
- LSEG Data Library for Python on the LSEG Developer Community website.
- Data Library for Python - Reference Guide
- The Data Library for Python - Quick Reference Guide (Access layer) article.
- Essential Guide to the Data Libraries - Generations of Python library (EDAPI, RDP, RD, LD) article.
- Upgrade from using Eikon Data API to the Data library article.
- Data Library for Python Examples on GitHub repository.
- DN092084-Decommission of ECON chains from Workspace
For any question related to this example or Data Library, please use the Developers Community Q&A Forum.