Hi everyone!
I'm trying to implement the wheel strategy on QuantConnect. If I try to sell a put option, how do I prevent the contract from exercising even if it is out of the money?
QUANTCONNECT COMMUNITY
Hi everyone!
I'm trying to implement the wheel strategy on QuantConnect. If I try to sell a put option, how do I prevent the contract from exercising even if it is out of the money?
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.
Louis Szeto
Hi Li Cheng
OTM put will not be assigned. For custom option exercises, you may refer to the DefaultExerciseModel to write your own ones, and set the OptionExerciseModel attribute of the Option object to your custom model.
Best
Louis
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.
Li Cheng
Hi Louis, I meant in the money, sorry for the mistake.
Unfortunately I don't understand C#, is there a way that I can adjust custom option exercises in Python?
I've attached a backtest in this message,, the code sells a put option and liquidates the position on the day of its expiry, is it possible for you to show me how to apply an exercise model that doesn't exercise any option? Essentially, remove the default exercise model so that no options will be exercised automatically.
Louis Szeto
Hi Li Cheng
Sorry that we haven't supported a Python implementation of custom option exercise models. Please subscribe to this GH issue to track our progress.
Best
Louis
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.
Li Cheng
Got you, thanks for the update Louis, will keep track of the issue!
Li Cheng
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!