About this template
This is a bot based on the OA study outlined in this blog post from @Steve Henry and @Kirk Du Plessis
https://optionalpha.com/blog/opening-range-breakout
They tracked SPY’s trading range at 15-minute intervals from April 25, 2022, through October 24, 2022, to see what patterns emerged in the opening range during this volatile time and found some patterns, so I wanted to build a bot around the findings.
While my other opening range based bot, ORB Bot_0-1DTE, looks to take short directional breakout trades based on technical readings, this bot uses the size of the opening range to try and determine how the trading day will play out and place a trade accordingly.
When I first read the study I was already in the process of modifying a version of @Viraj’s 0DTE Iron Condor w Iron Fly Hedging to test a variant idea I posted in his template about using Broken Wing IB's on bullish and bearish trends vs all Iron Condors, which seemed could be a good place to start with this bot… so you will see its influence throughout some of the logic and structure. Thanks Viraj!
10:30 Opening Range Group:
This event runs every day at 10:30 and uses the opening range size to tag the bot using the four, equal-sized groups identified in the study.
Scanner:
The bot tag from the 10:30 Opening Range Group event is used to determine the type of trade to place for the day:
up group1: opens a short put spread or long call spread depending on the IV level for a strong upward trend continuation
up group2, 3, 4 & down group2, 3: opens a bullish broken wing iron butterfly for a moderate upward trend continuation or a mean reversion
down group4: opens a short call spread or long put spread depending on the IV level for a strong downward trend continuation
down group1: opens a bearish broken wing butterfly for a moderate downward trend continuation
I also added a Technical Filters Toggle intended to look for secondary market condition confirmations to enter one of the above trades. But if the conditions are not met the bot will lastly check to see if there has been a move up or down greater than .5% and if NOT it will open a wide iron condor.
Default position sizing is 10% with a "Compound Mode" to switch between Net Liquid and Allocation (a feature for @Viraj's bot that I liked) ON = Net Liquid.
Default exit options are set at 50% profit.
Monitor:
I have been testing two different monitors:
1) A variant of @Viraj’s ITM Monitor modified to handle Spreads and IB’s as well as IC’s
2) A variant of my ORB Monitor
So far the modified ITM Monitor has had the best results, which is the default in the template. The ORB monitor locked in profits earlier in the day, but the ITM Monitor has had bigger wins by the end of the day. Mainly because it just kept the trades open longer, allowing the exit options target to trigger or close out with the market close automation. We’ll just have to see what the drawdown comparison is like once there are some losers.
Hedging:
The hedging logic is also an expanded variation of the hedging logic from the original bot that will open hedges if any of the positions become challenged.
This logic has not been tested yet, as no positions have become challenged at the time of sharing the bot.
For now the default is ON, but depending on performance that may change down the road.
Performance:
It needs a little more run time, but so far after almost a week the results have been promising at 4/4 wins. We’ll see if it continues to perform this well or if some additional modifications are needed along the way.
Cheers!
These are the various versions I've been testing in parallel and will share the ORB Monitor version in the comments below as well.