AlgoTraderAlgoTrader Documentation

Chapter 26. Synthetic Securities and Derivative Spreads

26.1. Combination Example
26.2. Combination Service
26.2.1. Create Combination
26.2.2. Update Component Quantity
26.2.3. Remove a Component
Combinations and Components

Figure 26.1. Combinations and Components


AlgoTrader supports Synthetic Securities & Derivative Spreads based on the two Entities Combination and Component.

Combinations are handled like every other Security. A Combination consists of one or many Components. Each component has a quantity.

When trading combinations there are two options:

  • tradeable / non-synthetic combinations

  • synthetic / non-tradeable combinations

For synthetic / non-tradeable combinations the AlgoTrader Server generates Ticks based on the size of the components of the combination and the current market values of the associated securities. This calculation is handled by the module module-combination.epl which provides the Component Window.

Note

It is possible to trade tradeable / non-synthetic combinations through the IB interface. For combination orders AlgoTrader will place BAG orders through the IB interface. For this to work it is necessary to have conids defined for all components of the combination.

On executions AlgoTrader will create fills for each component and for the combination itself. As a consequence there will be positions on all components as well as the combination itself.

A Combination is available to all strategies and can be subscribed/unsubscribed in the usual manner.


The example above shows a Combination based on 39 VIX April 2013 Futures and 5 VIX May 2013 Futures. The example shows that the market price of the combination is based on a weighted average of the prices of both combinations, e.g.:

(39 * 14.90 + 5 * 15.95 ) / 44 = 15.02

The CombinationService is responsible for handling all Combination / Component related DB-Operations.