Hi.
Two short questions about QC500:
- self.AddUniverse(QC500UniverseSelectionModel) doesn't work: there is an error. Is it OK?
2. I use SetUniverseSelection(QC500UniverseSelectionModel) instead. As I don't have access to the two filters, coarse and fine, anymore I cannot use the MarketPrice method. Is there a way to retrieve this information from the symbols inside OnSecuritiesChanged and OnData?
Thanks!
Fred Painchaud
Hey Skuperst,
Little detail, you should use AddUniverseSelection instead of SetUniverseSelection. But you can also bother with that later on. No issue.
If you want to add to the coarse and fine selection filters of QC500UniverseSelectionModel, you can inherit from it in a custom class that you create. I was lucky enough to find a small example of that here:
Fred
Skuperst
Hi again Fred, 😊
The post you sent me is exactly the source I learnt from about the self.AddUniverse(QC500UniverseSelectionModel) line.
The problem: it does not work, as you can see from the picture below.
It works only if I replace AddUniverse by SetUniverseSelection.
Thanks.
Fred Painchaud
Hello Skuperst!
Oh! It is then an excellent news I did not tell you to use AddUniverse but AddUniverseSelection!
And it is even better I told you that was a detail for now and that you could actually use that example to see that you can inherit from QC500UniverseSelectionModel, if you want to use a Universe Selection Model already developed but also define your own coarse and fine filters.
All those coincidences must form a little Christmas miracle!!
Cheers,
Fred
Skuperst
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!