Screener formula does not work in Eikon API

I am trying to use the same formula than Excel is retrieving me in Python and it is not working.

=TR("SCREEN(U(IN(Private(OrgType(COM, UNK, MKP)))/*UNV:Private*/), IN(TR.TRBCActivityCode,""5430102016""), IN(TR.HeadquartersRegion,""Europe""), BETWEEN(ZAV(TR.PCSmartRatiosLiquidityGlobalRank), 1.00, 20.00), CURN=USD)","TR.CommonName;TR.TRBCActivity"&";TR.HeadquartersRegion;ZAV(TR.PCSmartRatiosLiquidityGlobalRank)","curn=USD RH=In CH=Fd")


image


Best Answer

  • Gurpreet
    Gurpreet admin
    Answer ✓

    Hi @miriam.benito, Can you try this and see if it works for you:

    exp = "SCREEN(U(IN(Private(OrgType(COM, UNK, MKP)))), IN(TR.TRBCActivityCode,""5430102016""), IN(TR.HeadquartersRegion,""Europe""), BETWEEN(ZAV(TR.PCSmartRatiosLiquidityGlobalRank), 1.00, 20.00), CURN=USD)" fields = ['TR.COmmonName', 'TR.TRBCActivity', 'TR.HeadquartersRegion', 'ZAV(TR.PCSmartRatiosLiquidityGlobalRank)'] 

    df, e = ek.get_data(exp, fields)

    print(df)

    Here is my output:

         Instrument  ... ZAV(TR.PCSmartRatiosLiquidityGlobalRank)
    0 4298157373 ... 9
    1 4298203137 ... 18
    2 4298232673 ... 14
    3 4298253815 ... 14
    4 4298266156 ... 14
    5 4298270206 ... 3

Answers