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

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
1 0 2 4

How do I get the delta value of a stock at all strike prices on a given date through the EIKON API?

eikoneikon-data-apiworkspaceworkspace-data-apirefinitiv-dataplatform-eikonpython
icon clock
10 |1500

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

Upvotes
Accepted
38.1k 71 35 53

@yuyang

First, you need to know an option chain RIC for AAPL.O. You can contact the content support team via MyRefinitiv for an option chain. For AAPL.O, the option chain RIC could be 0#AAPL*.U.

Next, you need to know what field can provide the Delta Mid field. The Data Item Browser can be used to find fields. I found this TR.OPWMidDelta field that provides Option Watch Mid Delta.

With the option chain RIC and TR.OPWMidDelta field, the code to get the Delta Mid is:

df, err = ek.get_data('0#AAPL*.U',['PUTCALLIND','EXPIR_DATE','STRIKE_PRC'])
df1,err = ek.get_data(df.dropna()['Instrument'].tolist(),["TR.OPWMidDelta"])
df.dropna(inplace=True)
df.set_index('Instrument',inplace=True)
df1.set_index('Instrument',inplace=True)
df2 = pd.concat([df, df1], axis=1, sort=False)
df2





1594984332293.png (73.4 KiB)
1594984395572.png (25.1 KiB)
icon clock
10 |1500

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

Thank you very much for your answer. I have two more questions for you to answer.

1. Please look at the screenshot. On the Eikon client, you can choose the execution price and the specific expiration date. How do I pass parameters when I request data for Eikon python Api?

2. For 0700.HK, what the option chain RIC could be? For other Hong Kong stocks, how do I know his option chain RIC?

Hi @yuyang

2. You can use "OPTIONS" field.


1. It is not possible to filter out the underlying OPTIONS CHAIN RIC on the get_data()

However you can write your python code to filter out the data inside df dataframe according to your requirement such as EXPIR_DATE should be in some period and STRIKE_PRC should be some value.

ahs1.png (38.4 KiB)
Upvotes
6.7k 8 6 7

Hi @yuyang Thanks for your question. I take it you mean the delta value of an option.

So the screenshot you posted was of the option watch app which has a delta column in it.

From the Data Item Browser app (type DIB into Eikon Search bar) you can see there are different types of delta available (in this example I just used a S&P500 Aug put with the last delta value - but as some options can be illiquid you might also want ask, mid, bid etc based delta to get more recent value):

So you can use the TR.OPWxxx fields depending on your preference.

opw, err = ek.get_data('SPXt212029000.U', fields=['TR.OPWLastDelta'])
opw 


I hope this can help you.


1594982766979.png (316.4 KiB)
1594983713684.png (20.7 KiB)
icon clock
10 |1500

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

Click below to post an Idea Post Idea