ek.get_data for USD1YOIS=

Hi,
I am trying to retrieve information for Overnight Index Swaps. I have RICs like USD1YOIS= or COP1YOIS= and I am using the following code to get the data:
ts2,e2 = ek.get_data('USD1YOIS=',
["TR.MIDYIELD.date","TR.MIDYIELD"],{'SDate':start_date,'EDate':end_date,'Frq':'D'})
I have tried using the fields TR.MIDYIELD or TR.MIDPRICE but I don't get any information.
I have looked in the Data Item Brower for fields that have time series data but couldn't find any.
Do you know what field should I use? Thanks!
PD: I am able to get the data from an excel spreadsheet using =@RHistory and the field Close. However using the python code I can't get it.
Best Answer
-
@Andresgo Hi I would use the refinitiv data platform (RDP) library for this - which you can use with your app key:
import refinitiv.dataplatform as rdp
rdp.open_desktop_session('YOUR APP KEY HERE')
rdp.get_historical_price_summaries(
universe = 'USD1YOIS=',
interval = rdp.Intervals.DAILY,
count = 500)Please also note that the refinitiv.dataplatform library also contains a full version of the eikon library which you can use by:
import refinitv.dataplatform.eikon as ek
ek.set_app_key('Your App Key Here')So you can use both APIs from one package.
I hope this can help.
0
Answers
-
Hi @Andresgo,
You can try to use the timeseries function in Eikon data API. The data provided is intervalized bar data.
>>> ek.get_timeseries('USD1YOIS=', start_date='2019-10-10T15:00:00', end_date='2021-01-10T15:00:00', interval='monthly')
USD1YOIS= CLOSE HIGH LOW OPEN
Date
2019-10-31 1.371 1.535 1.296 1.502
2019-11-30 1.422 1.496 1.388 1.367
2019-12-31 1.498 1.513 1.415 1.425
2020-01-31 1.332 1.51 1.346 1.489
2020-02-29 0.901 1.45 0.849 1.334
2020-03-31 0.044 0.888 0.065 0.888
2020-04-30 0.034 0.082 0.05 0.064
2020-05-31 0.015 0.038 0.001 0.031
2020-06-30 0.018 0.054 0.031 0.002
2020-07-31 0.018 0.03 0.027 0.015
2020-08-31 0.037 0.056 0.035 0.007
2020-09-30 0.046 0.051 0.054 0.039
2020-10-31 0.051 0.062 0.063 0.031
2020-11-30 0.048 0.073 0.067 0.037
2020-12-31 0.066 0.073 0.081 0.063The TR.MIDYIELD field that you are trying to use is not applicable to Fixed Income Asset class.
For any more help regarding data, please raise a service ticket at my.refinitiv.com to speak to a content expert. We can only answer technical question on these forums.
0 -
Hi @jason.ramchandani01. Thanks for your help. This works! Quick question. I managed to get USD1YOIS using the following code.
OIS = rdp.get_historical_price_summaries(universe = 'USD1YOIS=',
start = "2005-12-31",
end = "2021-03-17",
interval = rdp.Intervals.DAILY,
fields = ['MID_PRICE'])
I tried to get more RICs like USD2YOIS or something else but I did get an error with the following code.
OIS = rdp.get_historical_price_summaries(universe = ['USD1YOIS=''USD2YOIS='],
start = "2005-12-31",
end = "2021-03-17",
interval = rdp.Intervals.DAILY,
fields = ['MID_PRICE'])
Do you know what is the right syntax to make it work?
Thanks!
0 -
Thank you! This works! However this get_timeseries has some data limits, hence to get a long history is impossible.
0 -
I think that it supports one item for each call.
rdp.get_historical_price_summaries(
universe = 'USD2YOIS=',
interval = rdp.Intervals.DAILY,
count = 500)0
Categories
- All Categories
- 6 AHS
- 36 Alpha
- 166 App Studio
- 6 Block Chain
- 4 Bot Platform
- 18 Connected Risk APIs
- 47 Data Fusion
- 34 Data Model Discovery
- 684 Datastream
- 1.4K DSS
- 613 Eikon COM
- 5.2K Eikon Data APIs
- 10 Electronic Trading
- Generic FIX
- 7 Local Bank Node API
- 3 Trading API
- 2.9K Elektron
- 1.4K EMA
- 248 ETA
- 552 WebSocket API
- 37 FX Venues
- 14 FX Market Data
- 1 FX Post Trade
- 1 FX Trading - Matching
- 12 FX Trading – RFQ Maker
- 5 Intelligent Tagging
- 2 Legal One
- 23 Messenger Bot
- 3 Messenger Side by Side
- 9 ONESOURCE
- 7 Indirect Tax
- 60 Open Calais
- 275 Open PermID
- 44 Entity Search
- 2 Org ID
- 1 PAM
- PAM - Logging
- 6 Product Insight
- Project Tracking
- ProView
- ProView Internal
- 22 RDMS
- 1.9K Refinitiv Data Platform
- 630 Refinitiv Data Platform Libraries
- 4 LSEG Due Diligence
- LSEG Due Diligence Portal API
- 4 Refinitiv Due Dilligence Centre
- Rose's Space
- 1.2K Screening
- 18 Qual-ID API
- 13 Screening Deployed
- 23 Screening Online
- 12 World-Check Customer Risk Screener
- 1K World-Check One
- 46 World-Check One Zero Footprint
- 45 Side by Side Integration API
- 2 Test Space
- 3 Thomson One Smart
- 10 TR Knowledge Graph
- 151 Transactions
- 143 REDI API
- 1.8K TREP APIs
- 4 CAT
- 26 DACS Station
- 121 Open DACS
- 1.1K RFA
- 104 UPA
- 191 TREP Infrastructure
- 228 TRKD
- 915 TRTH
- 5 Velocity Analytics
- 9 Wealth Management Web Services
- 86 Workspace SDK
- 11 Element Framework
- 5 Grid
- 18 World-Check Data File
- 1 Yield Book Analytics
- 46 中文论坛