Hello All
How do we eliminate nonsense equities, for example tickers like
WMIH
This (and others) is not an active tickers and yet they show up (complete with a volume)
How can these be eliminated, ideally at the course universe level?
We are currently using US stocks equities and yet they show up. Is there some other selection to use for the Russell 3000?
we also put on a dollar Volume ($1000000) and yet they show up
Please help
Mia Alissi
To filter out inactive stocks or stocks that do not meet certain criteria, you can use the Coarse Universe Selection feature in QuantConnect. This feature allows you to define a function that returns the symbols you want to include in your universe based on certain criteria.
In your case, you can use the
CoarseSelectionFunction
to filter out stocks based on their Dollar Volume. Here is an example of how you can do this:This function will return only the symbols of the stocks that have a Dollar Volume greater than $1,000,000.
As for the Russell 3000, QuantConnect does not currently provide a built-in method to select this specific universe of stocks. However, you can create a custom universe that includes the symbols of the Russell 3000 stocks.
Please note that the Coarse Universe Selection data is an aggregate of daily data that includes the daily close, daily volume, and the dollar volume (daily close * EMA30(volume)). So, it's possible that some stocks that do not meet your criteria may still appear in your universe if they meet these criteria at some point during the day.
Sources:
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.
John Hookway
Thank you for your response
< you can use the CoarseSelectionFunction to filter out stocks based on their Dollar Volume >
We've actually done that (I mentioned “we also put on a dollar Volume ($1000000) and yet they show up”), and we can't eliminate such stocks.
Is there anything else we could try?
Mia Alissi
I see, you've already applied a dollar volume filter. In addition to the dollar volume, you can also filter out stocks based on their price or whether they have fundamental data. Here's an example of how you can do this:
In this example, the function filters out stocks that do not have fundamental data, have a price below 5, or have a dollar volume below 1,000,000.
If you still see inactive stocks in your universe, it might be because they were active and met your criteria at some point during the day. The Coarse Universe Selection data is an aggregate of daily data, so it's possible that some stocks that do not meet your criteria may still appear in your universe if they meet these criteria at some point during the day.
Sources:
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.
John Hookway
We did apply a price (of > 5) the same as your example as it happens and yet it still showed up. Yet WMIH still shows up. It seems strange it would show up when WMIH has no price or volume
We will try the fundamental data filter.
Mia Alissi
It's indeed strange that the stock WMIH still shows up despite the filters. Adding the
HasFundamentalData
filter should help, as it will exclude stocks that do not have fundamental data. Here's how you can add this filter:If WMIH still shows up after adding this filter, it might be worth checking if there's an issue with the data for this stock. You can do this by logging the price and volume of WMIH when it shows up in your universe.
Sources:
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.
John Hookway
There's definitely something not making sense about the coarse selection results
I’ve double checked the code – attached – and we’re using all 3 filters
So, why would we be getting nonsense stocks like WMIH?
John Hookway
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!