Hi everyone,
I'm a software engineer fairly new to the world of finance. I've used a bit of down time lately to implement a very simple strategy so that I can learn more about how this platform works. Wanted to share it here in case other newbies find it helpful.
Background
I'm tipically an index fund investor. My more trade-savvy friends have been telling me to try a covered call strategy because it's relatively low risk and easy to implement. The covered call stragey I've back tested works like this:
- With all available cash, purchase .spy.
- Using these shares as colateral, sell a call (more on contract selection later).
- Place a limit order to buy back the call if the time value decreases.
Contract Selection
I chose to sell calls that expire 35 days in the future, with a target delta of 0.2. The limit order to buy the call back was placed as 20% of the initial contract premium.
Results
Running on data from 2008-2020 gave 2.3% returns. See the attached backtest. Here are some metrics that stand out to me:
SPY compounding return: 9.6%
SPY SR: 0.52
This strategy compounding return: 2.3%
This strategy SR: 0.27
Using the new parameter sweep tool (very cool!), it looks like returns can be improved by lowering the target delta from 0.20 to 0.05.
0.05 delta strategy compounding return: 9.2%
0.05 delta strategy SR: 0.56
Discussion
Overall this strategy underpeforms the market in return. With paramter tuning, the return may be brough near market returns. Sensativity to a parameter makes me suspect that this strategy is not fundamentally sound.
Overall, I would expected a covered call strategy to underpeform in a bear market. The analized data (2008-2020) is predominately during a bear market. It seems reasonable that selling options less likely to be exercised (lower delta) during this perioud would bring returns closer to market.
Questions
This is my first time doing one of these. Would love to get input from some experts around here.
- What would you have done differently?
- Any tips or tricks to make covered calls more interesting?
- Each run on 12 years of data takes about 1.5 hours, presumably due to needing to have minute resolution on options data. Has anyone found a good way to speed up run times for options strategies?
- For those who do parameter sweeps, how do you determine if you're overfitting? I'm thinking about doing my parameter sweeps on the first 5 years of available data, and then using the final 7 years of data as an evaluation set.
Regards,
Derek Melchin
Hi Nate,
Great job on this first algorithm! We recommend setting the warmup period to 30 days to ensure the options price model has sufficient data. In addition, we can replace the shares calculation logic with the CalculateOrderQuantity method.
To speed up the run-time, we can make the option filter more restrictive. For example, only subscribing to contracts that are within 5 strikes instead of 60.
Best,
Derek Melchin
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.
Nate Miller
Hi Derek,
Thanks for the expert insights! Great ideas, I'll implement them and see how it turns out.
David Eldringhoff
Hey, currently building a similar strategy on QQQ but was using options with DTE0. Did you work on this anymore? Find any better ways to improve the strategy?
Michael0000
Hi
Are there any updates to this strategy based off Derek Melchin's suggestions?
Nate Miller
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.
To unlock posting to the community forums please complete at least 30% of Boot Camp.
You can continue your Boot Camp training progress from the terminal. We hope to see you in the community soon!