Get Open net return prices

My code is this:
ds.get_data('DJES50I',['NR'], start = '2000-01-01', end = '2020-07-31')
and I just want to know how do I have to fill in the "Open" statement to make it work?
I`ve seen the other article, but that is way too much unnecessary code for me..
so is there an easy solution?
Best Answer
-
Hi @tom.oddotom.oddo,
If you are particularly looking for historical 'NR' ('Net Return') daily data, you may use the following:ds.get_data(tickers = 'DJES50I', fields = ['NR'], start = '2000-01-01', end = '2020-07-31', freq = 'D')
I tested it myself and it returns data as expected. I also verified the data returned by Datastream with our Refinitiv Workspace and can confirm that using 'fields = ['PO']' correctly returns Open Prices - i.e.: the EURO STOXX 50 index at the opening of the market.
0
Answers
-
Hi @tom.oddo
I am not sure what the "Open" statement refers (if you can elaborate that would be great).
However, I am going to guess from the ds prefix that you are trying to use DataStreamDSWS library
If so, the following works for me when I use my own Datastream username and password
import DatastreamDSWS as DSWS
ds = DSWS.Datastream(username ="myusername", password="mypassword")
ds.get_data('DJES50I',['NR'], start = '2000-01-01', end = '2020-07-31'if you are not using DatastreamDSWS then please state which library ds refers to.
Or if the above does not answer your question please expand on what you mean with (incomplete) code snippets if appropriate.
0 -
Hi,
yes thats right.
With "Open" I want the value of the stoxx 50 index at the opening of the market.
(I think the price I get is the close price)
Thanks in advance
0 -
Hi @tom.oddotom.oddo
You may find information on our DatastreamDSWS Python API's fields in several ways, either via the 'help' function:Via the 'Getting started with Python' found in our Refinitiv Developer Portal's Datastream Web Service's Documentation page, or - most probably what you are looking for :
Via 'product.datastream.com' (where you will need to log in with your Datasream credentials), where you may find information on DSWS data on the ticket 'DJES50I':
Once there, you may click on the 'More' option (that I pointed in red above for you) where you may find the exhaustive list of variables you may use in the 'fields' argument of 'DatastreamDSWS.get_data'.
In your case, I believe the best candidate is 'Price - Opening' with variable 'PO'; i.e.:
ds.get_data(tickers = 'DJES50I',
fields = ['PO'],
start = '2000-01-01',
end = '2020-07-31',
freq = 'D')0 -
Hi,
with the help function you dont see a lot.
The datastream link is good, but not what I want... I already knew PI and PO
but I want the open for NR , which doesnt seem to be available... that was the question.
Thanks
0
Categories
- All Categories
- 3 Polls
- 6 AHS
- 36 Alpha
- 166 App Studio
- 6 Block Chain
- 4 Bot Platform
- 18 Connected Risk APIs
- 47 Data Fusion
- 34 Data Model Discovery
- 685 Datastream
- 1.4K DSS
- 616 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
- 252 ETA
- 557 WebSocket API
- 38 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
- 653 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
- 27 DACS Station
- 121 Open DACS
- 1.1K RFA
- 104 UPA
- 193 TREP Infrastructure
- 229 TRKD
- 917 TRTH
- 5 Velocity Analytics
- 9 Wealth Management Web Services
- 90 Workspace SDK
- 11 Element Framework
- 5 Grid
- 18 World-Check Data File
- 1 Yield Book Analytics
- 46 中文论坛