Filter companies based on a compound keyword in the Business Description: normalization for singular
I am trying to understand how I should account for all possible cases, when I am looking for companies that contain a compound keyword in their Business Description. For the sake of illustrating my point, let us take the following company:
Company Common Name: Oxford Lasers Ltd
Identifier: 4296593425
Business Description: Supplies laser solutions to science and industry. The Company provides imaging solutions using digital high speed cameras, lasers and software. The Company also provides precision laser micro machining using repetition rate pulsed lasers to provide system solutions for industrial production.
Now let us say that I would be interested in finding all companies that contain laser solutions in the Business Description, but of course, I would also like to pick all variations around it: laser solutions, Laser solutions, Laser Solutions, LASER SOLUTIONS, laser solution, laser-solutions, lasers solutions, lasers solution ... and all the rest. I care about the meaning of the keyword.
I tested 8 different cases list above. The first 5 work (i.e. they return Oxford Lasers Ltd):
- laser solutions
- Laser solutions
- Laser Solutions
- LASER SOLUTIONS
- laser solution.
But the last 3 don't:
- laser-solutions
- lasers solutions
- lasers solution
The Business Description contains laser solutions. Interestingly, laser solution works, but lasers solution does not. It seems like the keyword search accounts for the singular of the typed word (when the word is plural), but it does not work the other way around: when the typed keyword is singular, its plural is not picked up.
I would like to know how I can pick all possible variations. I can experiment with all possible variations I can come up with, to infer what the code in refinitiv is doing, but it would be more efficient if someone told me directly what is going on in the backend. Therefore:
What is the piece of code that is processing the inputed keyword, as shown in the image below?
Or from my Jupyter notebook:
syntax = f"SCREEN(U(IN(Private(OrgType(COM, UNK, MKP)))),"\
f" IN(TR.HQCountryCode,""GB""),"\
f" IN(TR.TRBCEconSectorCode,""56""),"\
f" IN(TR.TRBCIndustryCode,""56101010""),"\
f" Contains(TR.BusinessSummary,\'{keyword}\'),"\
f" CURN=USD, TR.OrganizationStatusCode=Act)"
fields = ["TR.CommonName"]
df, e = ek.get_data(syntax, fields)
Best Answer
-
Hello @bm01 ,
I would approach this requirement in a certain way to be discussed next
(a quick disclaimer, I am a developer, not an Eikon content expert):
1. Run Eikon/Refinitiv Worspace Screener tool
2. Use it to define the exact Eikon screen expression, that you require
3. Export the ready screen expression as formula into Eikon/RW Excel.
4. Use the same expression in code.
For example:
Running "Screener"
Once you are satisfied you have included all the expressions per your requirements:
And then you should have in your Excel something like:
=@TR("SCREEN(U(IN(Equity(active,public,primary))/*UNV:Public*/), (Contains(TR.BusinessSummary,""Laser Solutions"") OR Contains(TR.BusinessSummary,""laser solutions"") OR Contains(TR.BusinessSummary,""LASER SOLUTIONS"")), CURN=USD)","TR.Commo"&"nName;TR.BusinessSummary","curn=USD RH=In CH=Fd")
This should allow to identify the max set, and that, once migrated into EDAPI code would look similar to:
syntax = "SCREEN(U(IN(Private(OrgType(COM, UNK, MKP)))), IN(TR.HQCountryCode,""GB""), IN(TR.TRBCEconSectorCode,""56""), "\
f" IN(TR.TRBCIndustryCode,""56101010""), "\
f" Contains(TR.BusinessSummary,""\"laser solutions\""") OR "\
f" OR Contains(TR.BusinessSummary,""Laser solutions"") OR "\
f" Contains(TR.BusinessSummary,""LASER SOLUTIONS""), "\
f" CURN=USD, TR.OrganizationStatusCode=Act)"
fields = ["TR.CommonName","TR.HeadquartersCountry","TR.TRBCEconomicSector","TR.TRBCIndustry","TR.BusinessSummary"]
df, e = ek.get_data(syntax, fields)
dfUsing this approach, you should be able to assess the result for correctness, iteratively, and tune the expression via screener, till the result is satisfactory per your requirement.
this relevant article "Find Your Right Companies with SCREENER | Eikon Data APIs(Python)" may be helpful in learning how to use Screener tool.
As a customer, you may also wish to contact Refinitiv content experts via Refinitiv Helpdesk Online -> Content -> Eikon asking to help you select the list of companies per your requirements using Screener, and next you can use the derived expression in your EDAPI code same as step 4; or if you would like additional or more in-depth information on the content that you require.
Hope this information helps
1
Categories
- All Categories
- 6 AHS
- 37 Alpha
- 161 App Studio
- 4 Block Chain
- 4 Bot Platform
- 16 Connected Risk APIs
- 47 Data Fusion
- 30 Data Model Discovery
- 608 Datastream
- 1.3K DSS
- 577 Eikon COM
- 4.9K Eikon Data APIs
- 7 Electronic Trading
- Generic FIX
- 7 Local Bank Node API
- Trading API
- 2.7K Elektron
- 1.3K EMA
- 236 ETA
- 519 WebSocket API
- 33 FX Venues
- 10 FX Market Data
- 1 FX Post Trade
- 1 FX Trading - Matching
- 12 FX Trading – RFQ Maker
- 5 Intelligent Tagging
- 2 Legal One
- 20 Messenger Bot
- 2 Messenger Side by Side
- 9 ONESOURCE
- 7 Indirect Tax
- 59 Open Calais
- 264 Open PermID
- 39 Entity Search
- 2 Org ID
- PAM
- PAM - Logging
- 8.4K Private Comments
- 6 Product Insight
- Project Tracking
- ProView
- ProView Internal
- 20 RDMS
- 1.4K Refinitiv Data Platform
- 367 Refinitiv Data Platform Libraries
- 3 Refinitiv Due Diligence
- LSEG Due Diligence Portal API
- 3 Refinitiv Due Dilligence Centre
- Rose's Space
- 1.1K Screening
- 18 Qual-ID API
- 13 Screening Deployed
- 23 Screening Online
- 10 World-Check Customer Risk Screener
- 990 World-Check One
- 44 World-Check One Zero Footprint
- 45 Side by Side Integration API
- Test Space
- 3 Thomson One Smart
- 1.2K TR Internal
- Global Hackathon 2015
- 2 Specialists Who Code
- 10 TR Knowledge Graph
- 150 Transactions
- 142 REDI API
- 1.7K TREP APIs
- 4 CAT
- 21 DACS Station
- 117 Open DACS
- 1.1K RFA
- 103 UPA
- 172 TREP Infrastructure
- 224 TRKD
- 886 TRTH
- 5 Velocity Analytics
- 5 Wealth Management Web Services
- 59 Workspace SDK
- 9 Element Framework
- 5 Grid
- 13 World-Check Data File
- Yield Book Analytics
- 46 中文论坛