Fetching a company’s TRBC codes

Hide code cell content
import refinitiv.data as rd

rd.open_session()
/home/runner/.local/share/virtualenvs/refinitiv-data-python-cookbook-I-HIyNf4/lib/python3.10/site-packages/refinitiv/data/_access_layer/session.py:71:FutureWarning: 
You open a platform session using the default value of the signon_control parameter (signon_control=True).
In future library version v2.0, this default will be changed to False.
If you want to keep the same behavior as today, you will need to set the signon_control parameter to True either in the library configuration file
({'sessions':{'platform':{'your_session_name':{'signon_control':true}}}}) or in your code where you create the Platform Session.
These alternative options are already supported in the current version of the library.
<refinitiv.data.session.Definition object at 0x7fd97871d090 {name='rdp'}>

You can use the Refinitiv Data Library for Python to retrieve the The Refinitiv Business Classification (TRBC) codes associated with a company. The standard is used by Refinitiv to classify business establishments for economic analysis.

To do acquire the data, pass a company’s Refinitiv Instrument Code to the get_data method with a request for TRBC related fields.

Here’s a query for Thomson Reuters:

rd.get_data(
    'TRI.N',
    fields=[
        # Basic stuff
        "TR.CommonName",
        "TR.TickerSymbol",
        # TRBC codes
        "TR.TRBCEconSectorCode",
        "TR.TRBCEconomicSector",
        "TR.TRBCBusinessSectorCode",
        "TR.TRBCBusinessSector",
        "TR.TRBCIndustryGroupCode",
        "TR.TRBCIndustryCode",
        "TR.TRBCIndustry",
        "TR.TRBCActivityCode",
        "TR.TRBCActivity",
    ]
)
Instrument Company Common Name Ticker Symbol TRBC Economic Sector Code TRBC Economic Sector Name TRBC Business Sector Code TRBC Business Sector Name TRBC Industry Group Code TRBC Industry Code TRBC Industry Name TRBC Activity Code TRBC Activity Name
0 TRI.N Thomson Reuters Corp TRI 52 Industrials 5220 Industrial & Commercial Services 522030 52203070 Professional Information Services 5220307010 Professional Information Services (NEC)
Hide code cell content
rd.close_session()