Back to Community
Robin Hood VIX Mix

Gotta give some real credit to James Wang https://www.quantopian.com/posts/trade-xiv-based-on-vix-1 and Anthony Garner and others.

This is the current version of Robin Hood Extreme Vetting https://www.quantopian.com/posts/robin-hood-extreme-vetting

There are alleged "risk-reducing" bits of code in this version. According to back test results, the more you "reduce risk" the less profits are made. Keep in mind I have lost multiple thousands of dollars live trading my algorithms. It seems like I learn more about real world behavior by live trading. I back test a lot first of course.

Pre warning: Don't follow me over a cliff, just because I so exuberantly jump!
I am all in UVXY right now including Robin Hood Gold.

This version can be adjusted to your risk tolerance including adding your own basket of ETFs / stocks as a set aside percentage of portfolio.
It, by default, eases into XIV and UVXY positions. That of course, according to back tests, greatly reduces profits.

Clone Algorithm
472
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58c0fd9608e3b261ac92d9c7
There was a runtime error.
149 responses

For anybody wondering, at the time that I started personally using this VIX - oriented algorithm, the "signal" to sell XIV and buy UVXY had already happened a small number of days before. So I manually bought into UVXY including all of my Robinhood gold. As far as I know, this algorithm will switch back and forth "as appropriate". The latest couple of versions do "buy into UVXY first" if that is the situation that the current level of VIX suggests according to the algorithm "rules". In case you are not aware, UVXY has daily decay, meaning it tends to lose money every single day.

I added dynamic stock selection as an option as a percentage of portfolio. I am live trading this. I am currently 100% UVXY though with a tiny percentage SH, including Robinhood gold.

Update: I found some minor logic / coding errors. You might consider using a later version.

Clone Algorithm
37
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58c66cfac3016a1363e2ada1
There was a runtime error.

100% UVXY is foolish, IMO. I have the rolling losses to prove it. Also, that's a k3 etf while tvix is better tax wise

How will Robinhood gold effect this algo. What happens when there is a margin call?

Feels like the current is turning today. Tomorrow w the Fed hike, let's see where your UVXY position takes you.

I'm there too.

Anyone trading this live using IB or Robinhood?

if it went 100% UVXY you'll be glad you didn't

http://vixcentral.com

monthly futures went from 14 to 13.5

Yep, I manually transferred half my UVXY to mostly SVXY and a small percent to LSVX. I was approaching the margin call and it seemed wise to hedge somewhat, so I did what I just said. Not 100% certain how my algo reacts to this specific situation. I may have to turn it off temporarily to avoid unwanted sell / buy. The nature of the beast I suppose.

I could be wrong. But I don't think the API for Robinhood Gold in Quantopian exists yet. So it is all manual transactions and trying to interpret how a specific algo will react to what you did. It does appear to be including the Gold in the portfolio value but not the cash available. I don't think the API for Robinhood includes margin yet.

Ok, in the current environment, if it continues, I may have to temporarily turn this off. But, this is what I am live trading as of now. I spent the last couple of days in SVXY.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58cbb24b70a28a1b3a35a539
There was a runtime error.

Tiny change in the custom graph. I got rid of Signal and put in XIV_30 because that is essentially one of the lines that XIV has to cross below to trigger a sell of XIV. Technically XIV_30 is actually XIV_30 + 2.7. I may have to tweak this in the current environment.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58cc072c7447601c04493617
There was a runtime error.

I spent a couple of days debugging and trying to get it to behave like I want it to.
I am live trading this version as of now.
I think even with an extended length of time down for UVXY, this may be ok to leave alone.
Of course, keep an eye on it, and decide for youself. Money may be lost. That is always possible.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58cdffeafd1e321780be07dd
There was a runtime error.
    context.SetAsideStocks = symbols(  
        'DWAS'  
        ,'NFLX'  
        ,'P'  
        ,'SNE'  
        ,'VXUS'  
        ,'AMZN'  
        ,'GOOG'  
    )  
    context.StayUnder1            = 0.05  
    context.SetAsideLeverageTotal = 0.50 - context.StayUnder1  
    context.XIV_BuyLeverage       = 1 - context.StayUnder1 - context.SetAsideLeverageTotal  
    context.UVXY_BuyLeverage      = 0.80 * context.XIV_BuyLeverage  
    context.NotUVXY_BuyLeverage   = context.XIV_BuyLeverage - context.UVXY_BuyLeverage

    # set up XIV  
    context.SoldXIV  = False  
    context.SoldUVXY = False  
    context.XIV     = symbol('XIV')  
    context.UVXY    = symbol('UVXY')  
    context.NotUVXY = symbol('BRK.B') # be sure is different from SetAsideStocks  
    context.VIXstocks = (context.XIV, context.UVXY, context.NotUVXY)

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58d02e68866b0e1759f3da2f
There was a runtime error.

So a possible "strategy" that might work if you feel like you are losing your shirt in UVXY is to sell UVXY and buy XIV (or SVXY or maybe LSVX), the algo will switch again the next time that conditions are met. If you really don't trust UVXY, then you can change context.UVXY to something you like or less painful. My algo allows you to fit your preferences. I am comfortable with the context.SetAsideLeverageTotal = 0.50 and context.UVXY_BuyLeverage = 0.80 * context.XIV_BuyLeverage. I did however manually sell UVXY after losing some money and manually buy SVXY. I think I'll stick it out this next time though. We shall see. Something that probably helps in the latest version of the algo is that it checks the XIV price against the XIV Average every 30 minutes and so hopefully will get out quickly during a XIV downturn if XIV and XIV Average are already close as is true today, not so for the UVXY though.

As always, be careful. Do your own research. You may lose money.

Maybe I jumped the shark, but I switched back into UVXY about an hour ago. Seems like a strong move.

I am long until my similar algo hits the sell point. I'm just going to let it cook for a couple years. If it is anything similar to the backtests, that would be an amazing story to tell. Otherwise, I have lost more in worse endeavors before.

If there is one thing we can trust on is that entropy is going up; therefore, events that trigger volatility will always exist, and potentially increase in number over time (disorder wins). Let us feed on fear! :)

the problem with uvxy is that the daily rebalance and double leverage combined with the high volatility of the etf pretty much ensure it loses money.

Might I recommend checking out VMAX?

Also my algo uses SQQQ as a pseudo long on volatility. It bought some today.

@James That is true. However, the algo only buys when volatility is low, and if you look at the daily transactions, once the VIX goes up, you make a killing selling it all, and buying XIV. So, I agree, if you stay in UVXY long and nothing else, you are going to lose no matter what. The instrument is designed to go down.

The hardest thing about this strategy/code, is that you won't see results short-term. I have read the data since the start of the VIX in Excel, and there are periods in which you are going to lose, and lose, and lose. Any normal investor would go insane looking at that on a daily basis. Second guessing the strategy, and wanting to pull out asap.

If live trading behaves even close to what the code is doing now, and you don't look at it (except to ensure the algo is working, since the Q connections go down once in a while), you might see your account at $0 at some point (if XIV gets shut down), or you might find that your investment is now millions due to the incredibly wild swings this strategy profits from.

This is a pretty cool experiment, regardless.

At what point would one need to update the static UVXY sell signal of >= 19.50? It seems as though at the moment there are sure to be occasional spikes in that neighborhood but eventually the overall decay would necessitate an update. Does it make sense to then calculate a signal dynamically based on some sort of averages value? The same logic applies for the XIV sell signal I would believe.

yeah don't use static values with the vix. The futures are always at a premium and usually in contango.

algo sold SQQQ for a small profit. Is your algo still holding?

I'm open to putting in a dynamic signal, if somebody proposes one. I'll start thinking about it myself as well.

I sold UVXY manually today at a profit.

This version flattens out a little most of the dips. Of course, the overall profits are also less. You should still watch it and make your own decisions. After all, it is your money at risk.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58d2a254166b721c0b4ecd79
There was a runtime error.

@Jay I don't know yet. That is a very good question. All hardcoded numbers should be dynamic instead. Those numbers worked in the past, as VIX, XIV, and UVXY have moved up and down inside those limits. But they might not work again as you said due to the constant decay or simply due to different market conditions.

A person in Reddit shared this argument: "One way to do this is to incorporate stuff like rolling correlation of individual S&P sectors with the S&P overall. When the correlation is low, the sectors are moving more independently of each other (like right now) and hedging each other, keeping volatility low. When they all move together, volatility is higher."

Have not explored incorporating this into the algorithm, or another strategy, but it is the right thing to do to avoid overfitting based on past performance.

@James Yes. Mine sold XIV and was supposed to buy UVXY on 2/24. The sale happened. The purchase didn't due to the connection dropping between Q and RH. Accidentally, that was a good thing, since I bought at a lower price (~$16), which right now gave me a small profit. But unless something more dramatic happens, pushing the market down, I expect that profit to disappear quickly.

@Chris Nice! I wrote an option right above. But I need to explore if there are better signals to use for this. I tried Google Trends, but that took me into at dead end. MarketWatch proposes SKEW. VIX options rates before expiration dates are another good signal. Will keep thinking in a simpler to implement set of numbers.

One idea that I saw listed in https://www.quantopian.com/posts/another-volatility-strategy-vix-levels-and-futures-ratios was going long in (mint) gold etf when conditions aren't great overall. Without subscribing to day trading, would it be beneficial to hold a so-called stable security like MINT in UVXY downswings while we wait for XIV spike conditions?

At any rate - the above listed algo seems interesting but the owners have not gotten it to execute live, due to faulty data setups it looks.

I found some logic errors that were leaving too much unused leverage or in rare cases exceeding 1.0 leverage.
This version is obviously not seeking max profit, but great profit while flattening, a little, all of the DDs.
I am live trading this. I think it might be ok to leave this one alone. But, perfect storm, who knows?
Edit: I added code to more accurately show daily max leverage that is checked every minute.
Thanks to Blue for that code which I slightly modified to start at 0 before trading day so I can see when it goes down, which is also important to know.
https://www.quantopian.com/posts/max-intraday-leverage

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58d8ddb2a6e9c4178ec695b7
There was a runtime error.

All positive returns, never a DD, not possible, especially if seeking great returns.

I found a logic error causing set aside stocks to sometimes go higher than assigned leverage.

I am live trading this version now.
As always, make your own decisions. You may lose a lot of money.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58dd9207dc99501b57375572
There was a runtime error.

If anybody out there knows the exact changes needed to make this IB compatible, please post. I received a request from a IB Quantopian newbie requesting that. I am strictly Robinhood at this point. Also, if somebody is wondering, for this to trade unhindered in Robinhood, you have to keep your leverage at 1.0 or less. So Robinhood Gold doesn't help, unless you are going to make manual trades, but that somewhat defeats the purpose of algorithmic trading, for me at least.

Charles, can this be traded manually in real time? How soon does Quantopian show a signal? Can one just run this during normal market hours and trade it when it signals a buy/sell. Seems like slippage wouldn't hurt it too much.

Quantopian paper trading runs around 15 minutes later than realtime

The downside to trading manually is timing. There seems to be an advantage, at least for this algo, to trading at 1 minute after open and 5 minutes before close. If you are skilled at buying dips and selling spikes, then manual transactions may get a superior return. If you don't want to risk the algo automatically touching your real portfolio, then paper trading, as mentioned above, may be what you want.

Hi Charles,

I was reading your code and you mention:

context.VIXprice = The_Output["VixOpen"].iloc[0] # VIX at market open  

which was declared as

 The_Pipe.add(GetVIX(inputs=[cboe_vix.vix_close]), 'VixOpen')

You seem to use the previous close so you might want to adjust that in the comments so people dont think they will get the open as they dont as the vix moves overnight.

I changed it to VixClose and market close.
I also added a log to track XIV Min, price, and Max, same for UVXY.

2017-04-03 14:55 Rebalance:102 INFO VIX: 12.37 XIV: 72.63 72.63 72.63 UVXY: 16.32 16.32 16.32

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58e29aaae77b981c09843a28
There was a runtime error.

I had a chance to relax a little and look again at the triggers for getting out of UVXY and back into XIV. So I made it lean heavier toward XIV, and jump out of UVXY quicker, while still catching the occasional nice UVXY return with limited risk.
Anyways, I think this is a little improved while still keeping drawdown limited.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58e30877ee7e3e2098909c93
There was a runtime error.

Charles, first I would like to thank you for sharing your algorithms. I tried coding my own algorithms, and can never seem to get them to run correctly. So since getting into this whole quantopian thing I have been reliant on finding good algorithms shared by generous strangers such as yourself and tweaking them slightly to my liking. I have been live trading this one on robin hood for about a week now.

I noticed you mentioned there was no way to implement robin hood gold yet, however I just noticed an algo tonight that seems to implement it. Not sure how to get it working with your algo, but I'll post a clone of that one below, let me know what you think.

Clone Algorithm
16
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58e495ea0fedd6663f172c8c
There was a runtime error.

That is curious. I have doubts. Does anybody know anybody that is actually trading live with Robinhood Gold where the algo actually fills trades with more than the cash available without the order getting rejected by Robinhood? At some point, I will test this again.
The relevant lines appear to be:

# Set any algorithm 'constants' you will be using  
MIN_CASH = 25.00  
ROBINHOOD_GOLD_BUYING_POWER = 0.00  
    # Determine portfolio value we want to call '100%'  
    target_portfolio_value = context.portfolio.portfolio_value + ROBINHOOD_GOLD_BUYING_POWER - MIN_CASH  
    context.target_portfolio_value = target_portfolio_value  
    # Calculate how much cash we have to spend.  
    net_cash = context.portfolio.cash + ROBINHOOD_GOLD_BUYING_POWER - MIN_CASH

I know there is at least one complication (if it works at all). Buying power varies per stock with Robinhood.

A modest jump in max drawdown in 2012, barely moves rest of the time. A large increase in total return.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58e5bae069a08e657680b513
There was a runtime error.

Thanks for the shout out Charles. I don't remember who I cloned that from at the moment, but I'll try to find the original later and mention them in here.
Have you considered using SPX futures as indicators in this algorithm?
Again thanks for your work on this, you are a God among men for sharing.

Edit: First and foremost, thanks to min elmim above and whoever algo he cloned. I would not have attempted to use the full margin in the algo again if he had not posted that code.
Edit: If you cloned the just posted version, clone this instead. Much improved, in timing of Rebalance and also tweaked "record leverage" code for faster back testing.
Live trading this version now. It is very early. However, it does appear to be using my Robinhood margin AKA Robinhood Gold.
This version is likely to attempt more often to day trade. You should have more than $25,000 in your account and / or have Robinhood "day trade pattern prevention" enabled.
Disable any of the scheduled Rebalance that you do NOT want to do. Your choice.
Change the RhMargin in TarPer:

RhMargin = 3000.00 # Set to 0 if you do not have Robinhood Gold  

or you will get a lot of rejected buy orders.

Do your own research. Try to understand the risks. Make your own decisions. You probably will lose a lot of money now or later.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58e7f8ea95ac2c6540ac2dda
There was a runtime error.

Found where I got that algo from. Dan Whitnable shared it in a thread. I'll link to it below.
https://www.quantopian.com/posts/best-performing-algorithms

Do you have connection issues to Robinhood sometimes? If so how do you deal with it?

Yes I do. It is unfortunate and sometimes painful and inconvenient. It is a "free" service though, so hard to complain.
I just shrug it off and login again. Sometimes it requires a full relogin and sometimes not. I don't know the reasons why or not, I just do whatever is necessary to get it connected again.

fyi

maybe VMIN instead of XIV / SVXY but starts approx 20160601

maybe VMAX instead of UVXY / XVZ but starts approx 20160601

also VMAX is 1X not 2X like UVXY
https://sixfigureinvesting.com/2017/04/how-does-vmin-work

my experience with vmin is that the wide spread hurts you if you actively trade it. The spread is also very large in the morning. Likewise it barely squeaks by xiv in actual profit.

Would recommend vmax over uvxy since it does not bleed money from the leverage

VMIN paid out a very large $9+ /share dividend, trading 30% lower. Had to manually rebuy shares since my algo was holding today

Gotta give some credit to Dan Whitnable who posted a Robinhood friendly algo in https://www.quantopian.com/posts/best-performing-algorithms. I definitely got some ideas and code from there which I modified to my own purposes. Thanks to Min Elmim for bringing that post to my attention!

Hopefully this version will retry failed orders.
I also made it aggressively sell everything and buy a smaller UVXY position and have cash for the remainder. Feel free to change the code if you don't like that behavior.
Parts of this code, especially the retry orders part, I have never tried in live trading. So we shall see how it does.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58f04d2ff9c829652b9a52e3
There was a runtime error.
context.todays_orders.remove(original_order)  

should be:

context.todays_orders.remove(order_id)  

@Peter,
What is your logic for saying that?
To me it seems that either might work. But the original_order is how it was when I copy pasted it.
Did you do some debugging that shows original_order does not work?
I have not as yet attempted to debug this specific code. But to me, it looks good as is.

The algo running live errored out for some reason. I updated the following code to be more up to date and then restarted the algo live.


    # Setting to the current conditions to continue from stop / start of algo  
    # You may wish to set both to False and 0.00 for the min max pairs  
    context.LongVIX  = False  
    context.ShortVIX = True  
    context.XIVmax   = 67.49  
    context.XIVmin   = 62.67  
    context.UVXYmin  = 18.28  
    context.UVXYmax  = 21.49

I debugged it as it failed and it confuses the object for the ID

@Peter,
Thanks for the details. I think I can understand that happening as you described. I changed it in my personal copy. So future versions should have the change.

Change included now for
context.todays_orders.remove(order_id)

    # Setting to the current conditions to continue from stop / start of algo  
    # You may wish to set 0.00 for the min max pairs  
    #2017-04-24 14:53 Rebalance:114 INFO VIX: 14.63     XIV: 62.67 73.34 73.34     UVXY: 14.87 14.87 21.49  
    context.LongVIX  = False  
    context.ShortVIX = True  # default  
    # execute this code when algorithm is running with a  
    # Robinhood account else back testing  
    if get_environment('arena') == 'ROBINHOOD':  
        context.XIVmax   = 73.34 # 0 for back testing  
        context.XIVmin   = 62.67 # 0 for back testing  
        context.UVXYmin  = 14.87 # 0 for back testing  
        context.UVXYmax  = 21.49 # 0 for back testing  
    else:  
        context.XIVmax = context.XIVmin = context.UVXYmin = context.UVXYmax = 0

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 58ff470761d2f865a47d6386
There was a runtime error.

Added additional signal from Kory Huang algo at https://www.quantopian.com/posts/the-spy-who-loved-wvf-or-just-another-volatility-spy-strategy
The signal apparently is known as William's VIX Fix indicator a.k.a. the Synthetic VIX.
This has resulted in fewer significant DDs and overall smaller DDs.

    # Setting to the current conditions to continue from stop / start of algo  
    # You may wish to set 0.00 for the min max pairs  
    #2017-04-27 14:53 Rebalance:120 INFO VIX: 10.85     XIV: 62.67 75.08 75.08     UVXY: 14.18 14.18 21.49  
    context.LongVIX  = False  
    context.ShortVIX = True  # default  
    # execute this code when algorithm is running with a  
    # Robinhood account else back testing  
    if get_environment('arena') == 'ROBINHOOD':  
        context.XIVmax   = 75.08  
        context.XIVmin   = 62.67  
        context.UVXYmin  = 14.18  
        context.UVXYmax  = 21.49  
    else:  
        context.XIVmax = context.XIVmin = context.UVXYmin = context.UVXYmax = 0

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 5902e998ecc07265c4f3051c
There was a runtime error.

Interesting, I assumed that the new signal might outperform my already existing signals when plugged into my algo. Nope. It is the combination of "William's VIX Fix indicator a.k.a. the Synthetic VIX" with my already existing "signals" that produces superior results. That is my subjective opinion at least. It certainly appeals to my personal preferences.

At some point, I will change the code to automatically fetch the min / max prices, which would improve historical back testing, because the pairs would be relevant regardless of point in time.

so when i go through this, I get a draw down of 69%, that is extremely high. Any ideas on updates to the algo to combat this?

Clone Algorithm
0
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 5908d34f8885ce4526f01061
There was a runtime error.

Setting to the current conditions to continue from stop / start of algo

# You may wish to set 0.00 for the min max pairs  
#VIX: 10.59     XIV: 62.67 77.32 78,62     UVXY: 12.86 13.30 21.49  
context.LongVIX  = False  
context.ShortVIX = True  # default  
# execute this code when algorithm is running with a  
# Robinhood account else back testing  
if get_environment('arena') == 'ROBINHOOD':  
    context.XIVmax   = 78,62  
    context.XIVmin   = 62.67  
    context.UVXYmin  = 12.86  
    context.UVXYmax  = 21.49  
else:  
    context.XIVmax = context.XIVmin = context.UVXYmin = context.UVXYmax = 0

Received this runtime error when it retried a cancelled order:
BadOrderParameters: Attempted to place an order with a limit price of
That makes sense since I am only using market orders.
So I changed the code
from:
retry_id = order(
original_order.sid,
original_order.amount,
style=LimitOrder(original_order.limit)
)
to:
retry_id = order(original_order.sid, original_order.amount)

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 5909327230e6a561e1a701a9
There was a runtime error.

@Walter Greaney
This algo will likely always tend to have higher drawdowns than many other algos.
Having said that, make sure you are using the latest version.
There are differences in the code that can make a big difference.
Even so, this test shows 49% max DD which is still quite high.
There are other VIX algos on Quantopian that have smaller DDs. Some of them, I used code from for this algo, not necessarily to make DDs smaller though.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 590934b3a600fe667359494d
There was a runtime error.
    # Setting to the current conditions to continue from stop / start of algo  
    # You may wish to set 0.00 for the min max pairs  
    #VIX: 10.55     XIV: 62.67 76.96 78.62     UVXY: 12.86 13.43 21.49  
    context.LongVIX  = False  
    context.ShortVIX = True  # default  
    # execute this code when algorithm is running with a  
    # Robinhood account else back testing  
    if get_environment('arena') == 'ROBINHOOD':  
        context.XIVmax   = 78.62  
        context.XIVmin   = 62.67  
        context.UVXYmin  = 12.86  
        context.UVXYmax  = 21.49  
    else:  
        context.XIVmax = context.XIVmin = context.UVXYmin = context.UVXYmax = 0  

LOL, I, somehow put a comma where a period is supposed to be. This fixes that. Interesting that only live trading generates the error.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 590b31de29fbd765c55e96ed
There was a runtime error.

Anybody wondering why testing before 2012 with my algo does not give expected results?
The reason is I do not yet have proper code for handling NANs (not a number). So XIV and UVXY do not exist before 2012 and those NAN values never get properly replaced with real values when XIV and UVXY are born. My code does not handle that situation.

Great job coding Charles. Can you explain to me how the portion of code for Robinhood Gold works. Does it work in live trading?

Could someone also explain to me lines 52-63 of the code?

if trading live Robinhood, then those min / max pairs are populated with actual prices. Otherwise, they are populated with 0 initially.

Yes, the Robinhood Gold code works in live trading. Otherwise it would be worthless to me.
The key line is:
RhPV = context.portfolio.portfolio_value + RhMargin - DoNotSpend
Whatever your level of margin is with Robinhood, goes in RhMargin. Mine is 3000. You must adjust this to your situation. Be it 0 or something else. Or else you will get a lot of rejected orders.
In simple terms, Robinhood calculates portfolio value as positions value plus cash (not including Robinhood total available margin).
We simply add the margin to it. We then use the new value to calculate buy orders. It really is that simple.

Ok, having said how simple it is, now let me explain a caveat.
Robinhood has a formula (I don't know if it varies for different people.) for calculating how much of your own cash must be used on a specific stock.
For me, for XIV, it is 68% initial, and 60% maintenance requirement.
For me, for UVXY, it is 60% initial, and 50% maintenance requirement.
For me, for SVXY, it is 68% initial, and 60% maintenance requirement.
For me, for ZIV, it is 50% initial, and 25% maintenance requirement.
For me, for TQQQ, it is 80% initial, and 75% maintenance requirement.
So, you will still have an expected number of rejected orders when it hits the above limits.
Even so, in live trading with Robinhood margin, I have found it does use most of the available margin.
As your portfolio grows larger, margin is a smaller and smaller percentage of it, thus eventually zero rejected orders.
Maybe if I adjusted the DoNotSpend to be a calculated percentage of margin, it would completely eliminate rejected orders caused by the above limits.
Hope that was a simple yet thorough explanation.

Changed DoNotSpend
from
DoNotSpend = 25
to
DoNotSpend = 100 # Try to prevent margin - related rejected orders
From my own live trading with Robinhood margin, it seems that 100 cushion may be enough to prevent margin - related rejected orders.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 590e9c6f453b2465584611a5
There was a runtime error.

I appreciate the thorough response Charles. Any idea how the backtesting compares to live trading? This has been my greatest struggle when developing new ideas in the past.

Let me say first, these volatility - related investments are more risky. You can lose a lot of money.
Having said that, the potential for profits are undoubtedly real. My live trading for the last 30 days has profit of 20.12%. However, I have only been investing in these volatility - related ETFs since approx March 9th, 2017. From March 9th through approx April 7th, I did experience a significant loss. There is a learning / education that you have to go through before you can be comfortable in this kind of investment. I think I've finally turned the corner on this. I've had some hard lessons taught me as a result of emotional manual trades. I think I have the algo to a point that I can, for the most part, let it make the decisions. However, reality is that we, the humans, must still babysit it, even if just to restart the algo when it stops unexpectedly.

Also (putting this part in bold), UVXY will lose money 70 to 80 % (or higher) of the time. It can, occasionally have a great profit.

I think if you have thoroughly studied these ETFs and VIX and what they mean and how they behave, and are comfortable with the patterns and risk, it may be right for an individual. That is where I am.

I have, at least on one occasion, bought a week - long binary option to temporarily protect against a large drop in the stock market.

@charles - when flipping the switch on your current iteration are you required to manually buy in a percentage of UVXY or will the signal attempt to handle going long on UVXY during a VIX spike?

Hi, Charles have you thought about incorporating the vix futures ratio into this algo as a potential trade signal? Contango and backwardation are great indicators. Also, you could have your algo invest in leveraged gold etfs and leveraged spy etfs during specific market conditions.

@Jay - It attempts automatically to profit from VIX spike with UVXY. Most of the time though it jumps back out UVXY after a certain amount of loss. Fair to say, that most attempts will lose money. However, if you study the backtesting, maybe slightly less than once per year, it tends to successfully time the VIX spike and reap quite big profits. That is the only reason I am leaving UVXY in there, is for those rare big gains. The rest of the time I just jump back out of it after certain amount of losses pile up.

@Nick - I have considered those, but I am still a bit of a novice at implementing additional signals. Most of the time, when I attempt to improve the algo, I erase all the changes, because it made it worse.

Something I may try and look into if I have the time. I know you haven't been trading the algo for very long, but how does live trading compare to backtests ran over the same period of time?

Short answer, live trading results do appear to correlate with backtests.
Robinhood says I made +22.1% "past month".
Quantopian says I made +23.8% 04/08/2017 to 05/08/2017.

Longer answer, there are things that will affect your return:
starting cash for backtest different from starting cash live trading
backtest margin different from live trading effective margin, which can vary for various reasons
manual interventions
any actual slippage
my current code starts with zero in min / max pairs for backtests, different behavior from live trade in Robinhood

@Charles what about modifying your hedge based on ATR? I was thinking 5 days, but 3 days seemed to work the best, so I might be overfitting to this time period. I'm still learning so I apologize if its a N00B approach.
I added this on Line 126:

    # Load historical data for the stocks  
    hist = data.history(context.vxx, ['high', 'low', 'close'], 15, '1d')  
    # Calculate the ATR for the stock  
    atr_14 = talib.ATR(hist['high'],  
                    hist['low'],  
                    hist['close'],  
                    timeperiod=14)[-1]  
    atr_3 = talib.ATR(hist['high'],  
                    hist['low'],  
                    hist['close'],  
                    timeperiod=3)[-1]  
    if atr_3 < atr_14:  
        context.VIX_HedgeLeverage = 0.7  
    else:  
        context.VIX_HedgeLeverage = 0.375  
Clone Algorithm
2
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 59125384df85006528214ccc
There was a runtime error.

I rant backtests from 2012-Present and here are the months where returns varied.

Month Current New Change
Feb-13 -5% -5% 1%
Jun-13 7% 14% 7%
Aug-13 -4% -4% 1%
Sep-13 -9% -14% -5%
Oct-13 19% 23% 4%
Mar-14 -12% -11% 1%
Oct-14 13% 19% 6%
Dec-14 24% 31% 7%
Jan-15 16% 24% 8%
Jul-15 3% -3% -6%
Aug-15 51% 56% 5%
Nov-15 20% 29% 9%
Dec-15 11% 18% 6%
Jan-16 -15% -13% 2%
Oct-16 -14% -18% -4%
Nov-16 36% 43% 7%

@Charles I saw in Simons code how he decides to trade and copied something similar to that. Essentially, it seems like the money is made when volatility is not too high or not too low, so I copied his logic to check what the standard deviation of returns were, you can play around with it, but it helps get the max drawdown lower, and also increases the return I think (I'm not sure how much slippage affects the returns). The code has to be cleaned up, but I just wanted to show the idea. Let me know what you think.
Starting at Line 136, then Line 231, then Line 244:

    # Calculates standard deviations of ETF's only trade if not blowing up.  
    prices = data.history(context.vxx, 'price', 60, '1m')  
    rets = np.log(prices).diff().fillna(0)  
    std = rets.std()  
    uvxy_prices = data.history(context.UVXY, 'price', 60, '1m')  
    uvxy_rets = np.log(uvxy_prices).diff().fillna(0)  
    uvxy_std = uvxy_rets.std()  
    if context.ShortVIX and std < 0.003:  
        TarPer(context, data, context.UVXY, 0.00)  
        TarPer(context, data, context.XIV, context.VIX_GrowthLeverage)  
        SetAsideStocks = context.SetAsideStocks  
        SetAsideLeveragePositions = len(SetAsideStocks)  
        for stock in SetAsideStocks:  
            if not DataCanTrade(context, data, stock):  
                SetAsideStocks.remove(stock)  
                SetAsideLeveragePositions -= 1  
        SetAsideLeverage = float(context.SetAsideLeverageTotal / SetAsideLeveragePositions) if 0 < SetAsideLeveragePositions else 0.00  
        for stock in SetAsideStocks:  
            TarPer(context, data, stock, SetAsideLeverage)

    elif context.LongVIX and uvxy_std < 0.006:  
        TarPer(context, data, context.XIV, 0.00)  
        TarPer(context, data, context.UVXY, context.VIX_HedgeLeverage)  
        for stock in context.SetAsideStocks:  
            TarPer(context, data, stock, 0.00)  
Clone Algorithm
3
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 59129870551fd966771c2120
There was a runtime error.
    # Setting to the current conditions to continue from stop / start of algo  
    # You may wish to set 0.00 for the min max pairs  
    #2017-05-09 14:53 Rebalance:174 INFO VIX Short / Long: 9.77 True / False  
    #XIV: 62.67 79.63 80.79     UVXY: 12.12 12.48 21.49  
    context.LongVIX  = False  
    context.ShortVIX = True  # default  
    # execute this code when algorithm is running with a  
    # Robinhood account else back testing  
    if get_environment('arena') == 'ROBINHOOD':  
        context.XIVmax   = 80.79  
        context.XIVmin   = 62.67  
        context.UVXYmin  = 12.12  
        context.UVXYmax  = 21.49  
    else:  
        context.XIVmax = context.XIVmin = context.UVXYmin = context.UVXYmax = 0  

@Kurry - Thanks, those are helpful. I implemented with some slight changes. For one thing, full 1.0 leverage for long VIX if conditions are met. Smoothed out most of the drawdowns and max DD is now 38%.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 5912a69dfb3a8965c3a2083f
There was a runtime error.

I was looking over the tear sheet and thought I would post it here. The drawdown seems fine enough for me at least. After a 10% drawdown, I can just stop it for five to ten days, and it should be fine.

Loading notebook preview...
Notebook previews are currently unavailable.

I agree that stopping the algo and simply exiting either the losing position or all positions, is a reasonable option when conditions are scary. Then, when things seem more normal, turn the algo back on. Keep in mind, that without a change, the default in the algo upon startup is to go short VIX. I also have purposely, for my own "signals" that are still in the algo at least, made them favor going short VIX more often than long VIX.

I noticed that yesterday before close and again this morning after open, the usual adjustment trades did not happen. My initial thought was something is wrong. Then I remembered the additional "signals" especially std and std_uvxy restraints will sometimes prevent orders. So, I guess it is doing what it is supposed to do. I then proceeded to talk myself into just letting the algo do its job. As the weeks go by, I am more comfortable just observing it and not intervening, unless necessary to start the algo after an unexpected halt. Lately, it picks up right where it left off, if I restart it during the same session. It often, in that situation, does not require a full relogin.

What if code was added that stopped the algo and exited position when conditions are scary?

Sure, but I think it may not work out so well in practice. Scary to me, may not be scary to others, and vice versa. LOL, I guess we could configure a preference variable for "Hell no, I'm not leaving!", "As long as I've recently made truckloads of money, I am staying!", "Uhhh, if things look shaky, get me out NOW!", and "I am not sure I should be in here at all! Mommy!".

LOL sounds great, but like you said may be difficult to implement as desired. Sorry for being such a novice. Can you explain this stop/start code to me?
# Setting to the current conditions to continue from stop / start of algo
# You may wish to set 0.00 for the min max pairs
#VIX: 10.55 XIV: 62.67 76.96 78.62 UVXY: 12.86 13.43 21.49
context.LongVIX = False
context.ShortVIX = True # default
# execute this code when algorithm is running with a
# Robinhood account else back testing
if get_environment('arena') == 'ROBINHOOD':
context.XIVmax = 78.62
context.XIVmin = 62.67
context.UVXYmin = 12.86
context.UVXYmax = 21.49
else:
context.XIVmax = context.XIVmin = context.UVXYmin = context.UVXYmax = 0

If in Robinhood live trading, it prepopulates the min / max pairs otherwise starts with 0.

@Charles your algorithm is pretty cool. Thanks for sharing. I was experimenting, and if you hedge, you could push a lot of money through this thing.

Clone Algorithm
60
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 59151771e2449962001387a9
There was a runtime error.

Obviously, I'm live trading this one with $5k unhedged for entertainment purposes haha.

Clone Algorithm
60
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 591500ce08eb766681293245
There was a runtime error.

Try to hold as little as possible of that margin beyond end of day, and if zero then it is free. Margin hits 6.8 million during the run currently, a tad over 137 thousand percent of the original capital. Carried day-to-day, consider what the fee would be. About 1/3rd of the curve is margin. I'd love to see what would happen if a non-margin account could be modeled, the closest you can come is probably order_target_value against context.account.settled_cash while no open orders, give that a whirl. Only XIV and UVXY are ordered, fyi for the casual reader/visitor.

In case anybody is wondering, if you are using Robinhood, your margin is limited to $3,000 max.

@Kurry - I get an error with your algo. Do you know why?

@Charles- Why are your margins limited to $3000? Before switching mainly to IB my margins were much higher.

Were you with Robinhood? I suppose it is possible that they don't trust me with more money. I assumed $3,000 margin was their max for everybody.

@Charles, for me it is also limited to $3,000, but there isn't $5k in settled cash yet since I just deposited, but they do describe situations where margin goes past $50,000 and how they will charge 5% interest. It does seem that they will do margin greater than $3,000 in the near future, see here. I'll email them though. https://support.robinhood.com/hc/en-us/articles/213262686-Robinhood-Gold-Buying-Power I emailed support to get a higher margin limit and I will let you know what they say.

RHFRetailCommisionsandFeesSchedule.pdf They got back to me, there is definitely margin over $3,000. The fee schedule is above.

LOL Thanks Kurry! You bursted my bubble! I thought everybody was in the same situation as me. I am so conceited. You know, I recently broke two pairs of spectacles and had to order wider / longer spectacles to fit my big head!

This is great news though! It would appear that I will qualify for more margin soon.

The initial min / max pairs are populated automatically now. So there is no need to manually update the min / max pairs now when you stop / start the algo.
However, if you want it to start in long VIX (UVXY), then you will have to change:

    context.LongVIX  = False  
    context.ShortVIX = True  # default

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 5916c561faed65664bc0f9f6
There was a runtime error.

I thought about automatically adjusting the margin available based on account value. However, at a minimum, the amount of margin you have available is subject to what you, the investor, choose. So automatic adjustment of margin in the algo is probably not a good idea.

Modified Kurry's version so that it will not exceed cash + RHGold.

Clone Algorithm
16
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 59170d6bd917f449bb4b89dd
There was a runtime error.

@Charles do you think there is a way to tell the algorithm to sell shares in order to satisfy the margin calls that may inevitably occur?

Also, I please take a look at the version of the algo I just uploaded. The drawdown was only a few percent more compared to your most current version.

@Nick regarding margin calls, I have not experienced a real margin call yet. I have received at least one email and on a couple of occasions I noticed my Robinhood app notified me of margin call conditions, but there was not a "You must sell or deposit by this date / time". So far Robinhood has not sold my shares without my first telling them to do it. So, I am not sure how needed automatic selling to satisfy margin calls would be, nor do I currently have any idea how to implement it since I am not certain when these real margin calls happen and how Robinhood implements them, and whether that behavior will be consistent.

@Nick and @Kurry,
Let me first say, I am hesitant to be critical. We are all learning, and I appreciate the helpfulness, community, and learning spirit of Quantopian staff and community. Also, I say that obviously I have found many times my own logic errors in my own algos since I began writing algos.

I may be misunderstanding the code, but I think both Kurry's and Nick's versions have the feel of a work in progress. I say that, because after looking at those versions, it seems that the algos are not doing what you think they are doing. There are important and apparently relevant functions defined that never get called. Seemingly important preference / customization variables are customized as if they are meant to be used, yet are bypassed with hard - coded parameters in the execution part of the code. In one of Kurry's versions, I don't think it is hedging when he thinks it is. Specifically, it goes half portfolio in SH regardless of whether XIV (short VIX) or UVXY (2x long VIX) are the other half of the portfolio. I think maybe he intended to purchase SPY when purchasing UVXY. Now, I consider myself very much a novice at the whole hedging methodology, so I may be completely misunderstanding the intent of the code.

Let me finish by saying again thanks, and I will leave it at that.

@Nick,
Since you asked me to look at your version, I thought I should give at least one specific opinion on it.

context.VIX_MinHedgeLeverage  = 1.0  
context.VIX_MaxHedgeLeverage  = 1.0 # if certain conditions are met  

Since both above variables are equal, there will be no variance in execution results.

VIX_HedgeLeverage = context.VIX_MaxHedgeLeverage if atr_3 <= atr_14 else context.VIX_MinHedgeLeverage  
    TarPer(context, data, context.XIV, 1.0)  
    TarPer(context, data, context.UVXY, 1.0)  

In the execution code, 1.0 parameter is hard - coded instead of using VIX_HedgeLeverage which would potentially provide variance in execution results.

Having said all that, if that behavior / results is what you intended, then I suppose it is fine, because it accomplishes your purposes.

Because it does full 1.0 regardless of the perceived safety of doing so, it gets higher max drawdowns. That is my subjective opinion. Also, keep in mind, in the code that I write I am probably using the word "hedge" in not exactly the way that hedging enthusiasts would use the word. I strictly mean with "hedge", "reduce my bet" if the risk seems measurably higher. My usage of the word may be unauthorized. 8)

@Charles Thank you! Yes, it is a work in progress, please dear god I hope no one trades with the code I've written.

Sorry about posting the unfinished one up there. I'll finish it in the next couple of days and post it. I was working on this one, which is a modification of this algorithm. https://www.quantopian.com/posts/a-year-of-live-trading#5821739c31cc4004ca000bd4

Clone Algorithm
11
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 5917ec12fd778949b1ba8677
There was a runtime error.

If I switch it to just rebalancing at the end of the day, the performance is much better.

Clone Algorithm
11
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 5917f5a2bafde36223e8f8be
There was a runtime error.

Finally addressed the problem of NaN min / max values I think.
Also, tweaked the min / max code to improve performance in more date ranges.
2014-06-01 to 2017-04-12 does have a smaller return though.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 59197efccb78ba618ddc4200
There was a runtime error.

Posting this now in case you don't like the next version.
This uses VMIN instead of XIV if available.
Before anybody asks, VMIN paid a large dividend at the huge dip. It think it shows that big dip only because of timing. You might say it is a race condition causing that. For you programmers, forgive me if I used the term "race condition" incorrectly.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 591a1a18272edf6196e8b697
There was a runtime error.

This is for risk averse people I suppose.
Goes half portfolio in BXMX when in short VIX (XIV or VMIN).
BXMX buys calls to protect against market drops, but it pays large monthly dividends.

I am trading the previous version above. But I thought somebody might like this.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 591a2642ac826e61816f302c
There was a runtime error.

I have not looked at the code for these algos, but you can't use margins with VMIN. Does the code account for this?

I noticed that this morning. No, it does not. I am watching my algo as it live trades to see how it behaves under these conditions.

I think VMIN is not a good stock to trade unless limit orders are being utilized due to the very low volume. Also, I have noticed that set aside leverage only reduces drawdowns by a few percent at most and limits growth by much more.

With not being able to use margin for VMIN, I think that is a big enough disadvantage, that I decided to remove VMIN.
I also adjusted the margin to 6,000 and DoNotSpend to 300 to hopefully avoid rejected margin - related orders. Make sure you go to the TarPer section to customize that to your preference.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 591b240777fa1d62123f115c
There was a runtime error.

As far as set aside stocks / leverage is concerned, I am leaving that in there so that it is easy to implement if somebody / including myself prefers it. It can always be ripped out or minimized if somebody prefers not to use it.

Changed margin to 12,000 and DoNotSpend to 600 to try to prevent margin - related rejected orders. In the TarPer section, make sure you change that if it does not fit your preference.

Clone Algorithm
571
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 591c48ee0df9de65fb332f88
There was a runtime error.

Does anyone live trading a version of this? If so, how is it performing today?

I'm trading a version...down ~5% today sitting in VIX and TQQQ.

But I've been manually trading UVXY in a separate account throughout the day to soften the blow. :)

freaking brutal, I'm down 13% total for my trading account today from this. I almost stopped the algo yesterday when I was up 7% from starting it 2 weeks ago and sold everything and I'm really kicking myself that I didn't.

It will be interesting to see how this plays out. In backtesting, I did see max drawdowns at around 40% so a drawdown of this nature is nature is only a matter of time. What is important to consider when live trading is how the live trading compares to backtests. If the backtests begin to show major deviations from live trading then I would stop the algo.

The real question for anyone live trading, stay the course or collect your losses?

I'm keeping the algo active, although it closed all positions (XIV, TQQQ) just before the bell and went all in on UVXY...which gets me nervous! It might work out if the volatility continues tomorrow but we shall see.

I shut the algo down and went long UVXY shortly before close today, but interestingly a copy I had paper trading did the exact same thing 5 mins before close. Gave me some faith and maybe next time I'll just let it do it's own thing.

My algo held. Fortunately it dumped all of its XIV position a few days earlier and held about $500 worth of VMIN so my account is mostly intact. The cool part about VMIN is that it doesn't rebalance daily like XIV does (and it shorts xiv/svxy and vxx/vixy), so if things rebound tomorrow it should do much better than XIV.

I suspect my algo will do tomorrow:
1. It'll determine the short vix risk is too high and will liquidate it's VMIN position in the morning regardless of if the market rebounds tomorrow or not.
2. It'll bump the short upside way up (used for determining leverage when it re-enters a short position)
3. It'll establish a very large position in SQQQ or possibly SQQQ and VMAX depending on if SQQQ has high market beta or not

That said, it all depends on the signals.

My opinion is that this is a very large over-reaction, so it's likely things will die down. Unfortunately, my algo tends to enter SQQQ right as things rebound and eat a loss... but whatever, when the market eventually tanks it'll make money hand over fist. Futures curve is in contango with most recent month below current VIX so the belief this will blow over appears to be the predominate one.

http://vixcentral.com/

@ James- Is your algo a variation based on Charles algo?

@min elmin- I have had the algo paper trading since 5/15 and it bought XIV at the end of the day.

No. My algo is custom, but it is predominantly ViX based. Turns out my algo bought xiv this morning

@nick - the one I had paper trading was an older version of the algo, so not sure what the latest would have done. I doubled down on UVXY with this bump after open and probably should turn a profit later today. Overall though I wish I left the algo running as this type of emotionally based buying and selling is killing me.

Yes I'm not sure leaving the algo running would have been great. That dip put me below 25k so Im restricted on a day trading standpoint. The algo bought more UVXY this morning which has tanked 10% so far today and I cant sell it. I have since canceled the algo. Down about $7k in 24 hours. Algo is continuing to plunge since the market is rebounding today and its invested in shorting the market right now.

Agreed. Though I think it allows room for improvement in the UVXY signal area, perhaps incorporating from other vix-related algos that were on the right side of yesterday's plunge.

Interesting my paper trading version that I started on the 15th bought XIV yesterday afternoon and more this morning.

Any idea how it would perform in an 08 type scenario

Did this thread just die off?

I was in process of depositing chunks of money each day into the algo, when one of the days was the big drop last week. That was unfortunate. I have now gained most of that drop back. Part of my loss was made larger because of a manual trade I made during 1 or 2 days last week. I was not real confident in the most recent version because it does not do twice daily rebalancing, at least those trades are sometimes not executed because of the most recent code deciding not to execute it. So, I wasn't sure if it was going to work. It appears I would have lost less if I would have just let the algo make all the decisions. Of course, again, as you all experienced, not babysitting it at all is not possible, both for technical and emotional reasons.

Restating the obvious, you may lose lots of money.

Posting because might be useful to somebody. It may not be appropriate for your situation. Make your own research and decisions.

This last week I began drawing a daily income from my Robinhood broker account.

if daily loss or daily profit < $100, withdraw $10
if daily profit >= $100, withdraw daily profit * 0.10
This provides for almost $200 minimum monthly cash flow to my checking account.
The maximum monthly cash flow to my checking account will grow depending upon the success of the algo / investments.
The almost 90% of daily profits remain to continue to potentially earn more profits.

You will have to adjust margin and / or DoNotSpend to make sure there will probably always be enough settled cash to make the daily withdrawals.
Margin does have a cost that is paid to Robinhood.
Make it work for you. These are your decisions to research and make.

@charles, would not mind seeing your automated withdrawal process. Can you please share?

It's not automated. Completely manual. It forces me to keep an eye on the algo though, so that is probably good.

Macro Investor and Peter Bakker and Stephen Kearney and probably others have posted some interesting VIX algos in
https://www.quantopian.com/posts/deployed-two-xiv-slash-uvxy-slash-tqqq-strategies-for-paper-trading-dot-dot-dot-will-make-it-live-trading-after-a-month
and
https://www.quantopian.com/posts/vix-trading-algorithm-return-150-percent-a-year-over-past-5-years-but-has-50-percent-drawdown-from-2015-meltdown

I of course have my own preferences that some of you have probably gotten accustomed to. I am looking at integrating some of their ideas.

Hi Charles, I am a part time daytrader and not really a programmer, although I am working with some people on some algos now. I just read through all the robin hood posts and am glad to see such an active thread. Thank you for that. Your posts are amazing. I have also read other threads about algos using the VIX, particularly trading XIV.

One thing I did notice is how slow the algos are to react to severe price movements like the one we had in mid May. The algo I am paper trading now completely missed the move and would have given up significant profits if it weren't for the bounce back to new highs.

Any thoughts on how to combat these quick rapid drops? I ask because I think we may see another significant drop soon and run up of volatility. 1. A lot of hedge fund guys talking about gold 2. Summer tends to slow down and 3. the current price action and indicators look similar to other volatile months for the VIX. 4. political news

Compare current RSI, MACD and price to RSI, MACD and price movement of summer of 2012. They are both diverging. Sure we may recover over time, but it would be nice to see an algo handle these quick dips in a timely manner. I know it;s no easy feat and I guess you can always turn off the algo for a bit.

Anyway, thanks again for the posts. I hope you continue to reap profits.

Edit: This is closer to what I intended. If you already cloned, then please clone again.

Macro Investor and Peter Bakker and Stephen Kearney and probably others have posted some interesting VIX algos in
https://www.quantopian.com/posts/deployed-two-xiv-slash-uvxy-slash-tqqq-strategies-for-paper-trading-dot-dot-dot-will-make-it-live-trading-after-a-month
and
https://www.quantopian.com/posts/vix-trading-algorithm-return-150-percent-a-year-over-past-5-years-but-has-50-percent-drawdown-from-2015-meltdown

I of course have my own preferences that some of you have probably gotten accustomed to.

Here is the version that I am now live trading. I still need to do some additional code clean up.
A lot of credit goes to those other guys I mentioned.

Remember you probably will lose a lot of money at some point. It is difficult to avoid.
In other words, make up your own mind if this stuff is worth the risk.

Clone Algorithm
167
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 593d845e0d545970ed83ed34
There was a runtime error.

Hi Charles,

Great job I love the improvements. Curious to why you are live trading this version over the version that you posted last night. The code is very similar but the returns are drastically different.

@Nick
Basically, the returns don't tell the whole story. I wanted it to fit more situations and also be more logical, from my perspective anyways.

@all
I did some reformatting of the logging. The statistics at the end is a work in progress because it does not account for when SyntheticVIX disagrees with BigSignal except for when BigSignal is TQQQ. Not sure I want to combine the two signals into the same section because I like that SyntheticVIX may disagree at the morning rebalance but agree with BigSignal at the afternoon rebalance. Anyways the logs should be easier to comprehend now. More code cleanup / reorganization is needed, but it is functional.

Clone Algorithm
167
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 593f4ebb3d3fa069ea44a100