Incomplete Screener with delisted stocks missing despite checking the box.

Niklas Landsberg
Niklas Landsberg Newcomer
edited May 27 in Eikon Data APIs

Hi,

I aim to get a complete list of all companies, listed and delisted, worldwide.
As such, I used the SCREENER command and checked to include delisted stocks as well.
I noticed, however, that the data is incomplete. Many delisted stocks are not included in the universe despite explicitly checking for delisted stocks. For instance: AGL.MI^G23, BVIC.L^A25, HRH.CO^A24, and many more. I realized that because I have an initial list of rics from a previous retrieval that might have delisted in the meantime. The screener command without any filtering in the API nor the Screener in workspace captures these stocks. However, I could explicitly add them to the include and then they are retrieved. As such, I wonder why they are not included in the universe-call or am I making a mistake?

fields = ["TR.CommonName;TR.InstrumentType;TR.LegalEntityIdentifier;TR.OrganizationID;TR.InstrumentDescription;TR.IsCountryPrimaryQuote;TR.PrimaryRICCode;TR.InstrumentName;CF_NAME;TR.HeadquartersCountry;TR.ISIN"]
universe = "SCREEN(U(IN(Equity(active or inactive,public,primary,countryprimaryquote))))"

companies, _ = ek.get_data(universe, fields=fields)

While you see that this call is for primary quotes, the same problem is also prevalent for all issues.
As such, the list of stocks is incomplete, and survivalship bias prevails.


Thank you in advance!

Tagged:

Answers

  • Jirapongse
    Jirapongse ✭✭✭✭✭

    @Niklas Landsberg

    Thank you for reaching out to us.

    I am sure if that screener formula will work. I tested it and it returned "UDF Core request failed. Gateway Time-out Requested universes:". The API is not designed to request a lot of data at once. Otherwise, the request could be timeout.

    get_data: The limit value is around 10,000 data points for version 1.0.2 and below. No enforced limit for version 1.1.0 and above. However, it still has a server timeout around 300 seconds.

    Moreover, this screener formula doesn't work on the Workspace Excel.

    You may need to contact your LSEG account team or Sales team directly for the solution that is suitable for this requirement (getting a complete list of all companies, listed and delisted, worldwide.)

  • Niklas Landsberg
    Niklas Landsberg Newcomer
    edited May 27

    Dear Jirapongse,

    Thank you for your answer!

    Indeed, the API call is unstable but it worked in my case since the timeout command is set very high. Before I even did it in partitions to prevent the timeout. I provided the lines of code yesterday to give an idea of what data I am requesting in the API. I checked that the full data is retrieved of 151.051 stocks which matched the Workspace Screener.

    Nevertheless, could you please check the following and advise?
    If you filter for only stocks in Italy (country of incorporation or country of exchange) , the call is much smaller and yields 1915 stocks with the delisted and primary issue checked.
    AGL.MI^G23 is a company that has been listed in Italy but delisted in 2023 as you can see by the RIC. It should appear in the SCREENER universe since the only filter is the country. However, it does not.
    I attached the Excel from the Workspace Screener to give you the formula just for this particular case but it is the same for the API.

  • Jirapongse
    Jirapongse ✭✭✭✭✭

    @Niklas Landsberg

    Please contact the Workspace Excel support team directly via MyAccount and attach this excel file.

    The support team can verify why the formula doesn't return AGL.MI^G23.

  • Niklas Landsberg
    Niklas Landsberg Newcomer
    edited May 27

    Thank you!

    I received a response by the content team and would like to share it below in case someone is wondering about the same issue in the future.

    "Companies which have transitioned to private status may not appear in current results. To view these, set the universe to Private Companies within the SCREENER tool. Once this adjustment is made, the companies you are looking for should be included in the results. However, I would like to set the expectation that including private companies will significantly increase the number of results, which may exceed SCREENER’s capacity to display them all. To manage this, we recommend refining your search by applying additional filters such as TRBC Sector and other relevant criteria to narrow down the results effectively."

    The Private Screener has the "Instrument Listing Status" data item which can be filtered with "DEL" for delistings. It works very well.

  • Jirapongse
    Jirapongse ✭✭✭✭✭

    @Niklas Landsberg

    Another method could be the Search API in the LSEG Data Library for Python.

    For example:

    response = search.Definition(
            view = search.Views.EQUITY_QUOTES,
            filter = "AssetType eq 'EQUITY' and ExchangeCountry eq 'ITA' and RCSAssetClass eq 'ORD' and IsPrimaryIssueRIC eq true",
            select = "DocumentTitle, RIC, AssetState",
            top=10000
    ).get_data()
    
    response.data.df
    

    This Search API can request at most 10,000 entries per request. You can refer to this Building Search into your Application Workflow article for more information.

    The examples are on GitHub.

    You may need to contact the helpdesk team to refine the search filter.