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

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
3 0 0 0

historical prices for bonds

Hi, I'm quite new in this community.

I'm trying to get in python the historical prices of a bond (RIC: "IT451364=", ISIN: "IT0004513641") but I only get historical yields

df = ek.get_timeseries(["IT451364="], 
                       start_date="2016-01-01",  
                       end_date="2016-01-10")

I also tried get_data but I only get the latest price

fields = [ek.TR_Field('TR.BIDPRICE')]
data, err = ek.get_data(["IT451364="],fields)

Is there any way to get the historical prices?

Thank you very much

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.

1 Answer

Upvotes
Accepted
18k 21 12 20

Hi @luca.monno

You can try this code:

df,e = ek.get_data('IT451364=',['TR.BidPrice.Date','TR.BidPrice'],
                  {'SDate':'20160101','EDate':'20160110','Frq':'D'})
print(df)



ahs.png (12.2 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