Back

Intraday Mean-Reversion Strategy (TVIX - VXX )

Here's a simple attempt at a mean-reversion/stat-arb startegy using TVIX & VXX. 8.7 Sharpe with very little drawdowns looks way to good to be true. As is, this startegy isn't tradeable because I dont think enough slippage has been taken into account but I am interested in seeing if anyone else can improve on this or has had any luck with mean-reversion. I have been trying to develope a stat arb strategy using the universe selection and a cointegration class that I wrote but it is extremely processor intensive.

Update Backtest








I believe they are difficult to short. A short-and-hold on the TVIX would also produce massive gains (if possible). 

Six figure investing provides some additional arguments. https://sixfigureinvesting.com/2016/10/is-shorting-uvxy-tvix-vxx-the-perfect-trade/

0

I've shorted both through IB, usually plenty of shares available but you have to be careful with position sizing as anything related to VIX can move very quickly and result in a margin call.  The main problem with this algo is the amount of trades it makes due to being an intraday strategy. Slippage almost always kills your profits if your trading timeframe is fairly short. I've run some short term tests and it looks like shorting any of these results in slippage values 3-4 times what is already accounted for in the algo. Hopefully someone can run with this and make it profitable. I definitely would not recommend a buy and hold with TVIX or any of the VIX related products unless it is a fairly small percentage of your portfolio as the spikes can be crippling.

0

Hello James:

I tried your example but the backtest just ends in 2013. Any ideas?

0


@James why the backtest stops after 10000 trades?

0

@Durable I just re ran it and it seems to be working fine. Try re-cloning the original?

0

Hi Durable, free users are capped at 10000 trades. Trades use a massive

amount of storage in the cloud believe it or not! Its basically 1-2MB per

backtest of purely trade storage per backtest.
0

The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.


1) There's still alpha if you don't short (but risk is greater ofc.)

2) The main problem is the small gain trades are going to be eaten by IB's fees I think your slippage setting is much too low, a quick calculation on TVIX share price shows your slippage is going to be at least 0.2% per trade, i.e. buy/sell pair. With a 44% win rate, the effective slippage paid for a winning trade is going to be more than two times that. Conincidentally, the amount won per trade is 0.1% something, i.e. eaten by slippage.

Could a variant of this be made to work? Not ruling it out, but I quite often any unmined alpha I come across proves too expensive to extract.

0

Arghh like usual - missing an edit post feature to fix grammar...

0

A thought: Maybe you can find some broker that does not charge a fee proportional to trade size?

I know my Swedish broker has an option to charge a fixed fee, but unfortunately they don't support algo trading (they do have US equities however). I could implement a hackish web crawler interface to them in Lean if I really wanted though. :p

0

Actually never mind, they've introduced a 0.079% minimum. Too good to be true TM

0

That said, the fixed fee with 0% fractional fee remains on Swedish equities. Now, if I could just connect with Lean... ;)

0

Also, apologies all about the spam. I've been working far too long today to the point of my eye sight starting to fail and I normally rely on edit post functionality to incrementally update my written thoughts...

0

What's the story with Tradier? They have fixed commissions, and used to have a relaationship with QC (but, apparently no more...)

 

0

We suspended Tradier's API as it was not stable enough for quantitative based trading. We're waiting for a few key upgrades and will re-enable it when its safe.

0

The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.


Thanks, good to know! Their API is a lot cleaner than IB's, so it would be nice if it worked... Their commissions/margin costs are way higher, sadly.

0

By the way, I backtested the strategy all the way to April 7 2017, and the Sharpe from Aug 1 2016 to the present is -9 -ish (yes, that's negative). I guess someone DID decide that the arb was tradeable.

2


You are not using RAW prices, but adjusted prices, that's why you are getting these returns. Look at the trades, VXX did not cost $1000 in 2013, it cost $30.

0

Thanks Egor, why do you think that using adjusted would give a different

return profile?
0

The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.


Jared, comission and slippage are usually not calculated correctly, plus price movements, while identical in percentage terms, in absolute terms produce far better results than reaility. Consider ETF that costs $10 and moves $0.01 and one that costs $1000 and moves $1, but your code still thinks that 1 tick is $0.01, and that $1 becomes 100 ticks in profit, when in reality it's not. Back adjusting prices for most ETFs makes no sense, since all splits and reverse-splits are virtual, there are no assets to be adjusted, only screen prices.

0

Interesting thank you. We can calculate things with raw data too, it should

be a standard test for strategies.
0

The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.


Why Don't you use XIV instead of shorting VXX?

0

Shorting VXX has a higher margin requirement on IB, but can have a higher Sharpe. Moreover, due to the mechanics of these instruments there can be situations where both XIV and VXX fall in value at the same time, XIV is in other words not a perfect inverse of VXX.

Slightly off topic: IB recently upped their requirements because of people were going short vol en-masse. These are the new margin requirements on IB for short vol VIX products, someone might find this info useful:

  • Long SVXY or XIV: 100%
  • Short VXX or VIXY: 150%
  • Short UVXY or TVIX: 300%

 

1

IB people sure thing know something ... getting ready for a crash ;-)

0

Update Backtest





0

The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.


Loading...

This discussion is closed