How to reference a list of instruments stored in Excel and how to display financial period in CH?

Bianca01
Bianca01 LSEG
edited May 13 in Refinitiv Data Platform
  1. How to edit the syntax so that it will reference an Excel file containing up to 250 RICs?
  2. How to edit the syntax so that it will display the financial period in the columns (e.g. FY2018Q1, FQ2018Q2, and so on). Tried adding 'CH': 'Fd,Fperiod' but it did not work.

This is what I am currently working on:

import refinitiv.data as rd
rd.open_session()
df = rd.get_data(
universe = ['ORCL.K'],
fields = [
'TR.RevenueActValue(Period=1FQ2018:1FQ2025,Curn=USD)',
'TR.EBITDAActValue(Period=1FQ2018:1FQ2025,Curn=USD)',
'TR.NetProfitActValue(Period=1FQ2018:1FQ2025,Curn=USD)'
],
parameters = {
'Curn': 'USD',
'CH': 'Fd,Fperiod'
}
)

display(df)

Thank you in advance!

Answers

  • Jirapongse
    Jirapongse ✭✭✭✭✭

    @Bianca01

    Thank you for reaching out to us.

    I found the following page that shows how to read an excel file in Python.

    Then, you can assign RICs in the universe parameter as an array. For example:

    df = rd.get_data(
    universe = ['ORCL.K','IBM.N','LSEG.L'], …

    As far as I know, the CH parameter is only supported by the Workspace Excel. The library doesn't support this CH parameter.