An Automated Way to Start VIX Hedging
One of the beautiful things about shifting to fully automated trading on the new Option Alpha platform is the ability to finally clone and replicate entire trading strategies using bot templates. Bot templates allow anyone to build a trading strategy and seamlessly share the structure and details of that strategy with one-click. Today, I want to walk through an automated way to start hedging with VIX. I have no doubt that this discussion will spark some creative ideas, allow you to dream of what’s possible, and show you that the future of trading is incredibly bright once you adopt auto trading.
What People Will Do With Bots
- Bots run a micro strategy in your account. They’re like little portfolio managers that you deploy into your account to run entire strategies. They don’t run everything in your account unless you want them to.
- In the future, there will be different types of bots that people will create.
1. Core Position Bots
- These will trade your bread and butter strategies like iron butterflies, iron condors, long stock positions, and trend positions.
2. Tactical Bots
- These are bots that do the tactical implementation of specific trading strategies such as a swing trading bot that trades based on RSI indicators. If RSI is low, it makes a position. If RSI is high, it makes a position. If RSI is in between, it does nothing.
3. Hedging Bots
- This has never been possible before in this industry.
- Hedging bots will play a huge role in situations where a black swan event comes out of left field in the middle of the day when you’re not watching.
- For example, in the 2010 flash crash, the market swung so rapidly that it was almost like you couldn’t respond even if you watched the screen the whole time. People might worry that this will happen again. Thus we built the possibility of creating these micro-hedging bots that are always on and always watching on the auto trading platform.
- What if you could build a bot that, hopefully, never got used, but continuously watched the market for an intraday crash?
Enter The Flash Crash Hedge Bot
- The point of demoing this type of bot is not necessarily to say you should be making these types of bots but just as an example of how creative you can be with what you can build on the platform.
- The Twitter hack that happened a while back could have been a lot worse, where the hackers could have tweeted nuclear threats that could have had drastic market effects. In a hypothetical event like this, you might not be at your screen, so you could not respond accordingly, or you might not even know what to do even if you were at your screen. A bot like this could be set to react to specific market parameters that might be met in an event like this. It would act according to a plan you had already thought out and programmed it according to. It would be your “Bazooka Bot.”
A Walkthrough of the bot Kirk set up
Setting up the global settings of the bot
- We can tell the bot exactly how much capital it has to play with if it needs to use it, and you also can set up position limits.
- For example, you give it $3,000 to play with at max and instruct it to only get into one position. This eliminates the possibility that the bot could go crazy, entering 10 positions in a row during a flash crash scenario.
Setting up a scanner inside of the bot
- In setting up this scanner, you could, for example, build out an automation called ‘is the market crashing?’
- This automation continuously runs checking for a set of criteria. It behaves in the way you tell it if those criteria are met.
- Kirk created two groups of criteria rather than one, so the bot behaves one way if one set of criteria get met, or another if the second get met.
- The first set of criteria is, ‘is the S&P price down 10% since yesterday?’ If so, it executes a hedge. You can make the criteria whatever you want, though.
- The second set of criteria is a group of decisions, all of which have to be true for the bot to respond. The first asks if the VIX is above 40. If this is true, it then asks if the SPY price is below $300. If both are true, the bot executes its hedge.
- This decision tree has been designed because it’s not always the case that the VIX has a big spike and the market drops. It’s usually the case, but it couldn’t be the case in some particular situations.
*The beauty of this is that you can use strategies like this as templates and adjust them.*
The "Yes" path of the bot
- If the S&P’s price was down 10% since yesterday, or the VIX was above some value, or the SPY price was below some value and all that stuff was true, then the bot would go down the yes path.
- Kirk set the yes path to entail buying a long call option on VIX 30 days from expiration or closest to 30 days on the at-the-money strike and use all the capital available – basically buy as many contracts as it could for $3,000.
- Again, you could choose your yes path to be whatever you liked.
- Kirk’s bot checks every 15 minutes for his criteria, but you can also adjust this timer using boost-ups. 15 minutes is good for Kirk because sometimes the market can go through mini flash crashes and subsequent recoveries, in which case the strategy the bot enacts wouldn’t be necessary.
Creating a monitor automation
- Once the criteria and the yes path are programmed into the bot, Kirk’s build’s next step was creating a monitor automation called “hedge profit taker,” which looks for an opportunity to take profits only if the position gets executed.
- Thus, not only can you set the automation to automatically enter a position, but now you can tell it what to do once it gets into that position.
- What is cool about the monitor actions is you can set the bot to monitor any position that gets opened. You can set it to execute a certain set of decisions for short call spreads and a completely different set of decisions for short put spreads and a completely different set of decisions for iron butterflies.
- Kirk’s hedge profit taker says anytime any position is opened it goes through a continuous sequence of hedge profit-taking and makes decisions every 15 minutes.
- The first decision that it comes across is, “did the premium in the position increase by 250% since it was opened?” If so, it closes the position. This threshold has been set high for the hedge to be effective, and because 250% is enough of a threshold for a single day.
- If the position’s premium did not increase by 250%, it checks to see if the VIX is below 40. So 40 is the same line in the sand used to get in and get out of the position.
- Kirk could have a profit at this point, or he could have a loss. He could also set up another decision to say, ‘if the VIX is below 30 and I have a 50% profit, then close.’
- The idea is setting up these dynamic decisions that you can put right into the bots and into the automations to make them do whatever you want them to do.
*Now, all you need to do is turn on the flash crash hedge bot, and that’s it – it’s running! Hopefully, you don’t need to use it!*
Creating a template
- The next level of all of this and what makes it cool is now you can save your bot as a template and share it. People can use it or make it a starting point for their own trading recipes.
- For people entering into trading for the first time that finds all the decisions to be over their head, they can use some of these templates which provide a pre-built structure to get going on.
- Now, you need to start thinking about how you can use automation in your own trading. Start dreaming about, “What if a bot could do this?”
Building in hedging and adjustments internally
- You can also do something that we haven’t touched on. You can also build in hedging and adjustments internally into other bots that you’re trading. You can build in triggers and milestones that bots are reaching, or challenging points that get triggered inside of a bot where, if you have a put spread and get challenged on the put leg, the bot can sell a call spread. Suppose you have an iron butterfly and get challenged on a long wing. In that case, the bot can execute a hedging strategy, or roll a contract, or do something to hedge that position right within the framework. You can use these strategies internally in some bots.
*Hopefully, your mind is spinning with creative ideas about the things you can do with bots, and you are really excited about the future of trading using auto-trading.*
Option Trader Q&A w/ Mark
Trader Q&A is our favorite segment of the show because we get to hear from one of our community members and help answer their questions live on the air. Today’s question comes from Mark:
Hi, Kirk. My name is Mark. In the past, I have closed iron condors or butterflies and have left the protective legs on to expire worthless. Sometimes those legs go in the money after the market close and I get assigned the shares, then I lose money in the process of closing that position. I just realized that my interactive broker’s platform has a function that allows me to preset an option exercise action. For instance, I could set an action to lapse that outstanding option leg without being assigned the stocks even if it is in the money. Is that a good idea? Thank you.
Remember, if you’d like to get your question answered here on the podcast or LIVE on Facebook & Periscope, head over to OptionAlpha.com/ASK and click the big red record button in the middle of the screen and leave me a private voicemail. There’s no software to download or install and it’s incredibly easy.