Upgrade from Eikon -> Workspace. Learn about programming differences.

For a deeper look into our Eikon Data API, look into:

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
3 2 5 9

How can I pull historical implied vol surfaces to python?

Hi,

is there a way to pull historical implied equity vol surfaces (e.g. .STOXX50E) to python via eikon app or datastream app?

Thanks,

Steffen

eikoneikon-data-apipythonrefinitiv-dataplatform-eikonworkspaceworkspace-data-apivolatility
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
Accepted
39.4k 77 11 27

I don't believe the forwards and the dividends used to calculate the surface are available historically in Eikon. Strikes corresponding to the moneyness levels expressed in delta are available, but at the moment they can only be retrieved using legacy Eikon .NET API.
At the datafeed we only calculate the surface using the moneyness points expressed in delta. If you retrieve corresponding strikes you could interpolate the curve for the moneyness points expressed as percentage of spot. But as I said, currently the only interface available in Eikon that provides programmatic access to the strikes historically is Eikon .NET API.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Which field is the correct filed for the historic strike price? I can see "STRIKE_PRC" and "TR.STRIKEPRICE" - what is the difference?

If you have a new question, please always start a new thread. Otherwise your question can be easily missed. Threads that already have accepted answer are not monitored by moderators.
It helps to look at the field in Formula Builder wizard in Eikon Excel. Fields that don't start with "TR." fall under Real Time category. These fields come from the real-time datafeed providing streaming market data and are not available historically. TR.STRIKEPRICE falls under Time Series Data category. When viewing a field in Formula Builder the Series checkbox under the Parameters tab in Formula Builder wizard signifies the availability of historical timeseries for this field. The lack of Series checkbox displayed signifies unavailability of history.

Upvotes
18.2k 21 13 21

Hi @steffen.fuchs

Maybe this is the data you are looking for ?

I do not understand the data. I just retrieve the data using the output instrument as an input RIC.


ahs7.png (57.1 KiB)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvote
39.4k 77 11 27

The method @chavalit.jintamalit provided can only work for a short period of time back into the history until the most recent rollover date for the options. For any date prior to the most recent rollover date the composition of the options chain will be different from the current composition. We do however have a volatility surface for this index defined in terms of tenor and moneyness, which are invariant over time. This volatility surface is available from the chain 0#STXEVOLSURF. Here's an example of constructing this surface on a historical date.

chain_df, err = ek.get_data('0#STXEVOLSURF',['GV3_TEXT','GV4_TEXT'])
moneyness_labels = chain_df['GV4_TEXT'].tolist()[:17]
vol_surf_df = pd.DataFrame(columns= moneyness_labels)
ric_list = chain_df['Instrument'].tolist()
chain_df.set_index('Instrument', inplace=True)
chunksize = 50
for i in range (0, len(ric_list), chunksize):
    tmp_df = ek.get_timeseries(ric_list[i:i+chunksize], 
                               start_date='2018-07-16', end_date='2018-07-16')
    for x in tmp_df.columns:
        vol_surf_df.loc[chain_df.loc[x,'GV3_TEXT'],
                        chain_df.loc[x,'GV4_TEXT']] = tmp_df[x][0]
vol_surf_df
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
3 2 5 9

Thanks, Alex. That's exactly what I was looking for. Is it also possible to pull the corresponding forwards and dividends? How far into the past can I go? When I try pulling 2017 data, I get the error 'No data available for the requested date range'.

Also I would prefer the moneyness in terms of moneyness not delta (i.e. 95%, 100%, 105%... instead of 45DPut, ATM, 45DCal). What is the name of that field. I was looking at the data item browser in eikon but could not find anything helpful.

Thanks,

Steffen

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
3 2 5 9

Alex, is there also a chain equivalent to "0#STXEVOLSURF" for listed ETF options and single stocks? I am looking at "HYG" specifically.

Thanks,

Steffen

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
39.4k 77 11 27

These chains are only available for a handful of world indices. For individual stocks and ETFs you can retrieve volatility surface using TR.SurfVolMONEYNESS field, e.g.

ek.get_data('HYG',['TR.SurfVolMONEYNESS.Tenor',
                   'TR.SurfVolMONEYNESS.Range','TR.SurfVolMONEYNESS'])
There's no history available for these surfaces.
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
3 2 5 9

Thanks, is there also a way to pull the current forwards and its components (dividend, rate)?

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

I don't believe forwards are ready available, but you can get forecast dividends from the RIC HYGDIVCF.U and interest rates used in the volatility surface from the RIC 0#USDZ=R.

Upvotes
1 0 0 0

Hi do you know how i could retrieve Volsurface for Soybeans?

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.