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

ibtws Create IB Trader Workstation connection
getdata Request current Interactive Brokers data
history Request Interactive Brokers historical data
marketdepth Request Interactive Brokers market depth data
realtime Request Interactive Brokers real-time data
timeseries Request Interactive Brokers aggregated intraday data
close Close IB Trader Workstation connection
executions Request Interactive Brokers execution data
createOrder Create IB Trader Workstation order
orderid Obtain next valid order identification number
orders Request Interactive Brokers open order data
accounts Retrieve Interactive Brokers account information
contractdetails Request Interactive Brokers contract details
portfolio Retrieve 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?