I am trying to retrieve data for the ric TFMBSURF1 using the refinitiv-data python api

Options

I am trying to retrieve data for the ric TFMBSURF1 using the refinitiv-data python api.

I tried the below code:

import refinitiv.data as rd

start_date, end_date = '2025-07-16', '2025-07-21'

rics = ['TFMBSURF1']

rd.open_session()

df = rd.get_data(

universe=rics,

fields=['TR.SETTLEMENTPRICE.Date'] + ['TR.SETTLEMENTPRICE'] * (len(rics) - 1),

parameters={

'SDate': '{}'.format(start_date),

'Frq': 'D',

'EDate': '{}'.format(end_date)

}

)

rd.close_session()

but it is not retrieving anything.

How can I retrieve the vol surface for TTF via the python api?

and what about downlading a single implied vol delta ric?

df_vol = rd.get_data(

universe=['TFMB10P1M=R'],

fields=['TR.SETTLEMENTPRICE.Date', 'TR.STL_IMPVLT'],

parameters={

'SDate': '{}'.format(start_date),

'Frq': 'D',

'EDate': '{}'.format(end_date)

}

)

this is the code I am trying to use but it returns nothing

Answers

  • Hello @navamani.p

    Your formula is incorrect -

    fields=['TR.SETTLEMENTPRICE.Date'] + ['TR.SETTLEMENTPRICE'] * (len(rics) - 1),
    

    Moreover these settlement price fields are not available for this instrument. You can look at the IPA curves and surfaces examples provided with the new LD Library.

    For content questions, it is best to reach out to the LSEG MyAccount.

  • Ok so I cannot download the surface using the Ric TFMBSURF1. Is it right?

    and what about my second query? Downloading using the RIC: TFMB25P1M=R?

    If I try to download the latter using: fields=['TR.SETTLEMENTPRICE.Date'] + ['TR.SETTLEMENTPRICE'] * (len(rics) - 1),
    it does not work.

  • I put here again the code I was referring to:

    start_date, end_date = '2023-01-16', '2025-07-21'
    window, quantile, position, target_var  = 252, 0.05, 30*24*100, 100000

    rics = {'TFMB10P1M=R': 'TTF_10p',
            'TFMB25P1M=R': 'TTF_25p'
            }



    rd.open_session()
    df = rd.get_data(
        universe=rics.keys(),
        fields=['TR.SETTLEMENTPRICE.Date', '.CLOSE'],
        parameters={
            'SDate': '{}'.format(start_date),
            'Frq': 'D',
            'EDate': '{}'.format(end_date)
        }
    )

    rd.close_session()


    ##############################

    So, I want to download the individual historical delta points implied volatility.

     

  • You can use the Data Item Browser (DIB in Workspace) to see which fields are available for your instrument. Settlement Price is not one of them.

    To get history for an instrument, you can use the get_history function of the library.

    ld.get_history('TFMB10P1M=R', start= '2025-07-16', end= '2025-07-21', interval='1D')
    
    image.png

    For clarification regarding content, please reach out to LSEG MyAccount. We can only help with technical API related questions.