LEAN is the open source
algorithmic trading engine powering QuantConnect. Founded in 2013 LEAN has been built by a
global community of 80+ engineers and powers more than a dozen hedge funds today.
Alpha League Competition: $1,000 Weekly Prize Pool
Qualifying Alpha Streams Reentered Weekly Learn
more
I'm running into an issue trying to call self.AddOptionContract() for anything traded after hours, like SPY and IWM. Here's the log for a couple trades I'm trying to simulate:
2020-04-06 16:00:37 : No data loaded for SPY 200409C00267000 because there were no tradeable dates for this security.
2020-04-06 16:00:43 : No data loaded for UVXY 200417P00047000 because there were no tradeable dates for this security.
2020-04-06 16:02:15 : No data loaded for IWM 200515P00107000 because there were no tradeable dates for this security.
As far as I can tell, this data exists in QC from AlgoSeek, but AddOptionContract() doesn't seem to add the underlying or contract with extendedMarketHours set to True (source).
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.
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.
Rahul Chowdhury
39.9k
,
Hey Tabrez,
Although it may be possible to trade options after hours in the market, it's not possible to so on QuantConnect. Also keep in mind that the vast majority of options on U.S. stocks trade during normal market hours.
Best Rahul
0
Chris Higginson
847
,
Hi Tabrez,
I ran into this earlier as well. If you are running the lean framework locally you can go to your market hours database ( look at "data-folder" setting in config.json ) and create a new entry named "Option-usa-SPY", for example, if SPY is the underlyer. Make sure the end time extends to 16:15:00. Definitely not the best solution, but works for me so thought I would share.
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.
Loading...
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!