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
1 4 8 7

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

eikoneikon-data-apipythonrefinitiv-dataplatform-eikonworkspaceworkspace-data-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.

Please be informed that a reply has been verified as correct in answering the question, and has been marked as such. Thanks, AHS

Upvotes
Accepted
78.9k 250 52 74

@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 512.0 KiB each and 1.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
10.2k 18 6 9

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 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.