Quantopian's community platform is shutting down. Please read this post for more information and download your code.
Back to Community
Is Q500US a subset of QTradableStocksUS, can I only use Q500US?

Is Q500US a subset of QTradableStocksUS at all times?

Is it ok to submit an algo to competition that only trades Q500US?

Thanks

3 responses

The Q500US universe isn't guaranteed to be a subset of the QTradableStocksUS (often abbreviated QTU). However, as a practical matter, it generally is. The contest rules only require securities be included in the QTU. If one wants to further refine that universe they can. Something like the following should work in the contest.

from quantopian.pipeline.filters import QTradableStocksUS, Q500US  
my_universe = QTradableStocksUS() & Q500US()

Good luck!

Disclaimer

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 Quantopian. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. No information contained herein should be regarded as a suggestion to engage in or refrain from any investment-related course of action as none of Quantopian nor any of its affiliates is undertaking to provide investment advice, act as an adviser to any plan or entity subject to the Employee Retirement Income Security Act of 1974, as amended, individual retirement account or individual retirement annuity, or give advice in a fiduciary capacity with respect to the materials presented herein. If you are an individual retirement or other investor, contact your financial advisor or other fiduciary unrelated to Quantopian about whether any given investment idea, strategy, product or service described herein may be appropriate for your circumstances. All investments involve risk, including loss of principal. Quantopian 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.

I like the question and that the solution is quick and easy.

To view the differences, this could be run on any date or remove the assert and let it run multiple days. Over multiple days it is visible how dynamic they are.

2019-08-14 05:45 before_trading_start:32 INFO Stocks in Q500US not in QTradableStocksUS  
  ['CELG', 'CY', 'S', 'PNC', 'TSS', 'WMB', 'AGN', 'ANTM', 'AAP', 'WCG', 'MLNX', 'BX', 'NXPI', 'CZR', 'ZAYO', 'ONCE', 'DELL', 'FOXA', 'DOW', 'LYFT', 'ZM', 'BYND', 'UBER']  

My impression--could be wrong--is that the better contest entries often have more than 500 stocks so you might want to think toward Q1500US().

From that list Blue posted, it appears fairly new IPOs are included in Q500US, which are not included in QTU.

Also, worth double-checking, but announced acquisition targets may be included in the Q500, and are not supposed to be included in QTU (yet apparently are, at least sometimes). Acquisition targets will generally dampen your performance, so best to avoid them.