Fully automated futures trading

I am running my automated futures trading system live for over five years. I have had a few occasions where it encountered a circuit breaker. That was almost entirely limited to agriculture futures such as LE and HE, or grains. My system trades near the end of the trading day. If a circuit breaker gets activated during the day it mostly remains active for the remainder of that day. My software does not recognize that, so when it submits an order it gets not filled. I decided to ignore this, let the system try the following day. I'm too lazy to try and develop fancy code to recognize this situation and respond differently.

++1 for this. Circuit breakers are rare, and if you're trading slowly enough are irrelevant

Rob
 
I use IB's Adaptive Algo with Normal speed (after testing the various speed options). I've paid 73.5% of the bid-ask spread over the last year, so it's definitely better than using market orders. When I last asked Rob, his and my spreads paid were about the same (our numbers have probably changed since I last asked, so they many no longer be comparable). So I'd recommend it. It also helps solve the problem of how to trade instruments without realtime quotes. I think others may use a SNAP algo for that, but I just use the Adaptive Algo for everything.

As I've said I now use SNAP, and it will be interesting to see my execution figures for the last 12 months which I will get round to at some point.

Rob
 
There is a discussion in this in one of the final chapters of AFTS which everyone on this thread should already own 3 copies of
Rob

I actually have 2 copies :). I started with the kindle edition but when I decided to implement it I needed something on my desk to look stuff up and not wasting even more screen real estate with having the kindle app open.
 
2. When building the backadjusted prices I shamelessly used the rollcalendars from pysystemtrade. I did the roll/carry within +/-5 days of expiry + rollOffset and searched for a date that all the contracts have prices. Should I refine the search to find overlaps where there are not only prices but the volume is "maximized" across the contracts? My intuition is, that this kind of optimization does not have a big impact on the system performance and therefore can wait.

3. For time reasons I tend to not implement Rob's execution algo but use IB's adaptive algo. Has anybody experience with this? Is it any good?

4. At the moment I am a systematic stock trader (exclusively mean reversion) and want to diversify into trend following (the meltup Nov to Feb did cost me dearly). From your perspective, is it ok to do everything in one IB account? Or is this something I will regret and should create a sub account or some other structure.

5. I read in the blog and this thread that rolling via a spread trade is preferable if the spread market for that instrument is liquid. How can I determine via IB API if a market is tradable via a spread trade? Does IB have special symbols for calendar spreads? I have never seen that before.

Thank you so much for your help!

Since most of your questions have been brilliantly answered by others I will limit myself to what new information I can add.

2. I am not sure I'd class this as 'optimisation'. You can optimise when you roll, but there are more criteria than just the volume (again discussed in AFTS at length). Indeed there might be a benefit to rolling when there is less volume. So it's more a case of 'do the roll dates in pst accurately reflect what we could have done in reality, or are there times when it rolls on zero volume'? The answer is that they are pretty good for the last 10 years, but before that are pure backtest and so may have been times when it wasn't really possible to roll. The next question is, does this make sod all difference? And the answer is probably not. It will subtly change backadjusted prices and thus account curves, but to an extent you'd change your behaviour as a result unless you're massively overfitting. And you're not. Are you?

5. Yes IB Have special symbols for these. It's tricky to say whether you should use a spread trade or not, a lot is based on experience of me trying to submit spread trades and them having them fail. Mostly now I close my existing position and let DO decide whether to reopen in the next month (see discussion on other post).

Rob
 
I actually have 2 copies :). I started with the kindle edition but when I decided to implement it I needed something on my desk to look stuff up and not wasting even more screen real estate with having the kindle app open.

That doesn't count you need three physical versions if you are absolutely serious about trading, and you get a free kindle version with each anyway.

Rob
 
As I've said I now use SNAP
If I understood the SNAP mechanism correctly, then you are not guaranteed a fill. So you place your SNAP, wait a little bit and if the price moves away from you then you place a market order? I must have missed something, because this seems to be identical to first placing a limit order and then placing a market order.
 
Snap Mid allows you to place a mid-price order without knowing the current bid and ask (when you don't pay for the real-time data and only know 15-minute delayed prices). When I place these orders I never adjust them after, and allow them to fill or automatically cancel once GoodTillDate (which I set to something like 15 minutes) expires
 
Snap Mid allows you to place a mid-price order without knowing the current bid and ask (when you don't pay for the real-time data and only know 15-minute delayed prices). When I place these orders I never adjust them after, and allow them to fill or automatically cancel once GoodTillDate (which I set to something like 15 minutes) expires
Guess you cannot calculate any slippage or shortfalls without market data. You only calculate benchmark shortfall against your backtested price then? Sounds like a neat idea. I do all my trading in a company (tax reasons) and therefore IB rips me off with their market data fees for professionals.
 
Guess you cannot calculate any slippage or shortfalls without market data. You only calculate benchmark shortfall against your backtested price then? Sounds like a neat idea. I do all my trading in a company (tax reasons) and therefore IB rips me off with their market data fees for professionals.
You do eventually receive all the prices after 15 minutes, so I guess if you want to analyze your slippage from the historical data you can still do that by shifting everything 15 minutes back.. But for me for example I don't know if it makes sense, because I evaluate my forecasts in real time on the same 15-min delayed prices (for contracts w\o subscription), so if my decision to buy was made on the 15-min old price, but I then analyze slippage based on the actual current bid-ask spread at the time of the fill, I don't know if it's really correct..
I myself treat those delayed prices the same as real-time prices in my reports, and the only difference in real-time trading is that I use snap-mid instead of the limit orders with the "simple execution algo" when I know it's a delayed price. I had another idea before, to keep using the same limit-orders and algo for delayed prices, same as for true RT-prices, as if I just had a very big network delay., it might work I think, just some orders will be expiring unfilled when the price moves far away in the "wrong" direction during 15 min..
 
Last edited:
If I understood the SNAP mechanism correctly, then you are not guaranteed a fill. So you place your SNAP, wait a little bit and if the price moves away from you then you place a market order? I must have missed something, because this seems to be identical to first placing a limit order and then placing a market order.
My trade execution software is similar to this approach:
(*) If the bid/ask spread is only one tick it doesn't bother and crosses the spread. Place a LMT order with the ask price (in case of buy) or bid price (in case of sell).
(*) If the bid/ask spread is larger than one tick it places an LMT order at the midpoint and waits for one minute. If the order hasn't been filled by then the price gets modified to cross the spread.
With this approach I rarely have orders that don't get filled. I have never analysed the total cost saving from this approach but do notice that it often fills at the midpoint.
 
Back
Top