Quantopian's community platform is shutting down. Please read this post for more information and download your code.
Back to Community
T-Rex strategy

Concept from
http://www.signalplot.com/the-definitive-guide-to-shorting-leveraged-etfs/

This algo shorts both long and inverse x3 leveraged ETFs to exploit volatility drag.
I called it the T-Rex strategy because it has two short arms... heh..

The strategy can have some really bad trades, but thankfully stop losses are very effective and do not affect the overall productivity of this algo.

Here is an explanation.
Every week, get the percentage change for lookback period (60 days) for both long and short arm. Add both values together. Sort all pairs and pick the lowest sum, which should be the draggiest of all pairs. Short the pair for a week. Get out if you lose 5%.

5 responses

Same as above except with lookback period set to 20 days, and will only trade if there is volatility drag. More effective and less expensive from a shorting expense.

1st algo: Leverage hits 2, quickly shorts twice init cash, cash headroom for longs, low beta from the shorting. In my experience with that sort of liquidation condition, have to wait afterward to keep them from reopening immediately.
2017-02-17 13:00 pvr:144 INFO PvR 0.0205 %/day cagr 0.1 Portfolio value 19476
2017-02-17 13:00 pvr:145 INFO Profited 9476 on 29999 activated/transacted for PvR of 31.6%
2017-02-17 13:00 pvr:146 INFO QRet 94.76 PvR 31.59 CshLw 10000 MxLv 2.00 RskHi 29999 Shrts 19445
2017-02-17 13:00 pvr:234 INFO 2011-01-03 to 2017-02-17 $10000 2017-02-18 22:27 US/Eastern
Runtime 0 hr 6.1 min

Here is the leveraged x2 version. Are you even allowed to leverage a short x3 position?

Leverage hits 4.0 (2 is only end of day) and it placed 140,392 at risk to make only 27,213 for PvR of only 19.4%

I added a more conservative filter instead of just accepting a sum < 0, and changed the start date. The strategy is in the market only about 1/5 weeks. Anyone have any ideas on something productive during off weeks?