Documentation

This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English verison of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

Interactive Brokers

Access market data, submit orders, and request information through Interactive Brokers® using IB Trader WorkstationSM

For a simple example about order creation using Interactive Brokers, see Create an Order Using IB Trader Workstation. For a high-level overview about using Interactive Brokers functions in a workflow, see Workflow for Interactive Brokers.

Functions

ibtwsCreate IB Trader Workstation connection
getdataRequest current Interactive Brokers data
historyRequest Interactive Brokers historical data
marketdepthRequest Interactive Brokers market depth data
realtimeRequest Interactive Brokers real-time data
timeseriesRequest Interactive Brokers aggregated intraday data
closeClose IB Trader Workstation connection
executionsRequest Interactive Brokers execution data
createOrderCreate IB Trader Workstation order
orderidObtain next valid order identification number
ordersRequest Interactive Brokers open order data
accountsRetrieve Interactive Brokers account information
contractdetailsRequest Interactive Brokers contract details
portfolioRetrieve current Interactive Brokers portfolio data

Topics

Workflow for Interactive Brokers

Request market data, create orders, and request Interactive Brokers informational data.

Create Interactive Brokers Combination Order

This example shows how to connect to the IB Trader Workstation, create IB Trader Workstation IContract and IComboLegList objects, and create a combination order for a calendar spread.

Create and Manage an Interactive Brokers Order

This example shows how to connect to the IB Trader Workstation, request open order data, create IB Trader Workstation IContract and IOrder objects, and execute the order.

Request Interactive Brokers Historical Data

This example shows how to connect to the IB Trader Workstation, create an IB Trader Workstation IContract object, and request historical data.

Request Interactive Brokers Real-Time Data

This example shows how to connect to the IB Trader Workstation, create IB Trader Workstation IContract objects, and request real-time data.

Writing and Running Custom Event Handler Functions with Interactive Brokers

You can process events related to any Interactive Brokers data updates by writing a custom event handler function to use with Trading Toolbox™.

Was this topic helpful?