Datasets

Terminal Link

Introduction

Instead of using the data from QuantConnect, you can use data from Bloomberg EMSX through Terminal Link if you're in an organization on the Institution tier.

Supported Datasets

Terminal Link supports securities from the following asset classes:

Universe Selection

Universe Selection is available with the Terminal Link data provider if you download the data from the Dataset Market. The dataset listings show how to download the universe selection data with the CLI. For live trading, you'll need to periodically download the new data from QuantConnect Cloud, which you can automate with Python scripts. For example, the following tutorials explain how to download historical data and download daily updates:

Alternative Data

If you have licensed alternative data with QuantConnect, it works as expected with the Terminal Link data provider for research, backtesting, and live trading.

Download

To download Bloomberg DAPI data, open a terminal in your organization workspace and then run lean data download --data-provider-historical "Terminal Link" --data-type <data-type> --resolution <resolution> --security-type <security-type> --ticker <tickers> --start <YYYYMMDD> --end <YYYYMMDD> --terminal-link-connection-type DAPI --terminal-link-environment <environment> --terminal-link-server-host <serverHost> --terminal-link-server-port <serverPort> --terminal-link-emsx-broker <emsxBroker> --terminal-link-openfigi-api-key <openfigiApiKey>.

$ lean data download --data-provider-historical "Terminal Link" --data-type Trade --resolution Daily --security-type Equity --ticker NVDA,AMD --start 20240303 --end 20240404 --terminal-link-connection-type DAPI --terminal-link-environment Production --terminal-link-server-host serverHost --terminal-link-server-port serverPort --terminal-link-emsx-broker emsxBroker --terminal-link-openfigi-api-key openfigiApiKey

If you provide your credentials, your Lean configuration file saves them.

Research

To access Bloomberg DAPI data from the local Research Environment through Terminal Link, open a terminal in your organization workspace and then run lean research <projectName> --data-provider-historical "Terminal Link" --terminal-link-connection-type DAPI --terminal-link-environment <environment> --terminal-link-server-host <serverHost> --terminal-link-server-port <serverPort> --terminal-link-emsx-broker <emsxBroker> --terminal-link-openfigi-api-key <openfigiApiKey>.

$ lean research "My Project" --data-provider-historical "Terminal Link" --terminal-link-connection-type DAPI --terminal-link-environment Production --terminal-link-server-host serverHost --terminal-link-server-port serverPort --terminal-link-emsx-broker emsxBroker --terminal-link-openfigi-api-key openfigiApiKey

If you provide any of the preceding options, your Lean configuration file saves them so that you only need to run lean research <projectName> to open the Research Environment with the same options.

Backtesting

To run a local backtest with Terminal Link that uses data from the Bloomberg DAPI, open a terminal in your organization workspace and then run lean backtest <projectName> --data-provider-historical "Terminal Link" --terminal-link-connection-type DAPI --terminal-link-environment <environment> --terminal-link-server-host <serverHost> --terminal-link-server-port <serverPort> --terminal-link-emsx-broker <emsxBroker> --terminal-link-openfigi-api-key <openfigiApiKey>.

$ lean backtest "My Project" --data-provider-historical "Terminal Link" --terminal-link-connection-type DAPI --terminal-link-environment Production --terminal-link-server-host serverHost --terminal-link-server-port serverPort --terminal-link-emsx-broker emsxBroker --terminal-link-openfigi-api-key openfigiApiKey

If you provide any of the preceding options, your Lean configuration file saves them so that you only need to run lean backtest <projectName> to run another backtest with the same options.

Optimization

Follow these steps to run a local optimization job with data from Bloomberg DAPI through Terminal Link:

  1. Add some parameters to your project.
  2. Open a terminal in your organization workspace.
  3. Run lean optimize <projectName> --data-provider-historical "Terminal Link" --terminal-link-connection-type DAPI --terminal-link-environment <environment> --terminal-link-server-host <serverHost> --terminal-link-server-port <serverPort> --terminal-link-emsx-broker <emsxBroker> --terminal-link-openfigi-api-key <openfigiApiKey>.
  4. $ lean optimize "My Project" --data-provider-historical "Terminal Link" --terminal-link-connection-type DAPI --terminal-link-environment Production --terminal-link-server-host serverHost --terminal-link-server-port serverPort --terminal-link-emsx-broker emsxBroker --terminal-link-openfigi-api-key openfigiApiKey
  5. Follow the steps in the interactive wizard to configure your optimization job settings.

The lean optimize command also accepts additional options so that you can select Terminal Link and run the command in non-interactive mode. If you provide any of the preceding options, your Lean configuration file saves them so that you only need to run lean optimize <projectName> to run another optimization job with the same options.

Live Trading

To deploy a local live algorithm that uses Terminal Link as the data provider, open a terminal in your organization workspace and then run lean live deploy <projectName> --data-provider-live "Terminal Link" --terminal-link-connection-type DAPI --terminal-link-environment <environment> --terminal-link-server-host <serverHost> --terminal-link-server-port <serverPort> --terminal-link-emsx-account <emsxAccount> --terminal-link-emsx-broker <emsxBroker> --terminal-link-openfigi-api-key <openfigiApiKey> --brokerage <brokerageName> <requiredBrokerageOptions>.

$ lean live deploy "My Project" --data-provider-live "Terminal Link" --terminal-link-connection-type DAPI --terminal-link-environment Production --terminal-link-server-host serverHost --terminal-link-server-port serverPort --terminal-link-emsx-account emsxAccount --terminal-link-emsx-broker emsxBroker --terminal-link-openfigi-api-key openfigiApiKey --brokerage "Paper Trading"

Depending on the brokerage you select, you may need to provide some required brokerage options. To use a different provider for historical data, include the --data-provider-historical option. If you provide any of the preceding options, your Lean configuration file saves them so that you only need to run lean live deploy <projectName> --brokerage <brokerageName> to deploy another live algorithm with the same options.

To deploy the algorithm in QuantConnect Cloud while still using Terminal Link as the data provider, run lean cloud live deploy <projectName> --data-provider-live "Terminal Link" --terminal-link-environment <environment> --terminal-link-server-host <serverHost> --terminal-link-server-port <serverPort> --terminal-link-emsx-account <emsxAccount> --terminal-link-emsx-broker <emsxBroker> --terminal-link-openfigi-api-key <openfigiApiKey> --brokerage <brokerageName> <requiredBrokerageOptions> --node <nodeName> --auto-restart <enableAutoRestarts> --notify-order-events <enableOrderEventNotifications> --notify-insights <enableInsightNotifications> <requiredNotificationOptions>.

$ lean cloud live deploy "My Project" --data-provider-live "Terminal Link" --terminal-link-environment Production --terminal-link-server-host serverHost --terminal-link-server-port serverPort --terminal-link-emsx-account emsxAccount --terminal-link-emsx-broker emsxBroker --terminal-link-openfigi-api-key openfigiApiKey --brokerage "Paper Trading" --node "My Node" --auto-restart yes --notify-order-events no --notify-insights no

To deploy the live algorithm through the interactive mode of the CLI, see Deploy Local Algorithms or Deploy Cloud Algorithms.

Pricing

To view the prices of Bloomberg’s Execution Management Solutions, see Execution Management System on the Bloomberg website.

You can also see our Videos. You can also get in touch with us via Discord.

Did you find this page helpful?

Contribute to the documentation: