Interactive Brokers API

Discussion in 'Automated Trading' started by WhiteOut56, May 25, 2011.

  1. Can you get Level2 data via the IB API?
     
  2. L2 data is available via the api.

    Additionally, A user recently added this l2 support in IB to tradelink .

    So when using tradelink with IB, you can trade and backtest based on level2 data now in addition to normal l1 data.

    this obviously saves you from having to do it yourself.

    google tradelink or checkout tradelink.org for more info.
     
  3. Sorry for my ignorance but I am interested to hear your reasoning not to use a ready package like Ninjatrader or Multicharts which already have lots of ready and built in supporting functionality.
     
  4. LeeD

    LeeD

    Now we just need someone who sells 10 years worth of level 2 data and doesn't charge the cost of a brand new Porsche.
     
  5. LeeD

    LeeD

    Where existing platforms provide advantage is charting. Implemeting differnet types of charts, scaling, nice presentaion of axes, manual application of trendlines etc is a massive amount of work.

    Indicator libraries are a lot fo work too but there are a few free ones available.

    Backtesting is a double-edged sword. First, creating a basic backtester is fairly easy. Second, very few platforms allow users code in their own fill assumptions.

    Automatic execution is apparently one area where using a readily available "platform" is more often a bad idea than not:

    1)To start with, out of a number of platforms I follow only one vendor (ButtonTrader) actually tests new versions of TWS. Others either suggets to stick with a specific version... or even notify users post-factum when they hear of the problems from other users: "you shouldn't have upgraded but we can't help you if you have". So, compatibility with future versiion of TWS is a very laborious area... but absolutley most platform developers don't support it properly.

    2) If a platform has problem that matters for very few users, the developers may not fix it for years. For example, one popular platform converts stop-loss orders into stop-limit orders with the offset (between stop and limit levels) hard-coded at (I think) 2 points. It's OK for trading equity futures manually as the "limit" would prevent the trader from getting a very bad fill in thinly trading instruments due to "stop-hunting". However, for most foreign exchange futures 2 points is too large. Even worse, if due to important news (like QE2 was) the price moves against the trader by more than 2 points instanteneously, the stop will not get executed due to the limit price and can easily lead to a loss of 20 or more points. It's especially dangerous as the trader may think they are "protected" by a stop.

    3) If a platform lacks a feature, the developers may not rush to add it. Say, my favourite platform lacks order modification. So, if I want to move trailing stop, I have to implement cancelling existing stop, waiting for cancellation to be confirmed (to avoid double-fill), send a new order... or I can use broker API directly from the trading strategy bypassing the platform.

    4) Platform developers are often reluctant to implemet functionality that is broker-dependant. For example, OCO (one cancels other) orders are essential to avoid "target" and "stop-loss" being both executed resulting in a reversed position. What happens when one of the orders is only partially filled differs between brokers. (Say MB Trading implements TTO orders which are different from what most people understand as OCO.)
     
  6. Thank you for taking the time to post your answer on this.
     
  7. Bob111

    Bob111

  8. Would you mind sharing with us what platform this is?