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
23 1 3 5

Get maximum price of stock within a date range

How can I use Eikon API to extract maximum price of stock over a specfic date range? I am using python to extract the maximum price.

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

@f.hashim

Thank you for your participation in the forum.

Is the reply below satisfactory in resolving your query? If so please can you click the 'Accept' text next to the appropriate reply.

This will guide all community members who have a similar question.

Thanks,

AHS

Upvotes
Accepted
3.8k 4 4 6

@f.hashim

You can do it directly on a dataframe

df,err = ek.get_data('VOD.L',['TR.HIGHPRICE','TR.HIGHPRICE.date'],{"Sdate":'2020-01-01', "Edate":'2020-09-10'})
df[df['High Price']==df['High Price'].max()]
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
18.2k 21 13 21

Hi @f.hashim

For the today high, you can use get_data() and use "HIGH_1" field.

For historical data, you can use get_timeseries() and use "HIGH" field.


ahs1.png (11.4 KiB)
ahs2.png (28.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.

I need to get maximum value from the time series is there a field that can give a maximum of `HIGH` field over a specific date range?

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.