question

Upvotes
Accepted
41 1 0 4

rd.get_history returns duplicated datapoints

Hi all,

Can someone help me with those requests which returns duplicated datapoints ?


Request 1

import refinitiv.data as rd
rd.open_session()
res = rd.get_history(universe=["ESH2^2"], fields=["TR.CLOSEPRICE"], parameters={ "SDate": "2020-12-18", "EDate": "2023-03-18"}, use_field_names_in_headers=True)


Response

The last datapoint is duplicated several times

1683913932773.png



Request 2

import refinitiv.data as rd
rd.open_session()
test = rd.get_history(universe="SRAK3",
               fields=["TR.CLOSEPRICE","TR.SETTLEMENTPRICE","TR.OPENINTEREST","TR.HIGHPRICE","TR.LOWPRICE","TR.ACCUMULATEDVOLUME"],
               parameters={"SDate": "2023-02-03", "EDate": "2023-08-25"},
               use_field_names_in_headers=True)


Response

Inspecting by hand it shows that one line has the full information, where the ‘duplicated’ one have some missing field (and is not necessary the last line with that date, eg the 6th of march)

1683914086589.png



api#product#contentrefinitiv-data-platform-librariescodebook
1683913932773.png (24.6 KiB)
1683914086589.png (72.0 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.

Upvotes
Accepted
69.2k 210 49 69

The resolution is:

Actually, this is the behavior of the service. It is expected to use the previous date to fill the date which doesn't have data. To solve this problem please use the Fill=None parameter, as shown below.

=@RDP.Data("ESH2^2","TR.CLOSEPRICE.date;TR.CLOSEPRICE","SDate=2020-12-18 EDate=2023-03-18 Fill=None CH=Fd RH=IN",B2)

=@RDP.Data("SRAK3","TR.CLOSEPRICE.date;TR.CLOSEPRICE;TR.SETTLEMENTPRICE;TR.OPENINTEREST;TR.HIGHPRICE;TR.LOWPRICE;TR.ACCUMULATEDVOLUME","SDa"&"te=2023-02-03 EDate=2023-08-25 Fill=None CH=Fd RH=IN",W2)
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
11.9k 25 5 10

Hi @yaokoffi.kouassi ,

The moderators on this forum are expertise on Refinitiv APIs usage. However, they do not have deep expertise in every type of content available through Refinitiv products. Such expertise is available through Refinitiv Helpdesk, which can be reached via MyRefinitiv. To be of help, ticket number 12564679 was raised on your behalf and the support team is going to contact you soon to assist with this.

Hope this helps and please let me know in case you have any further questions

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.