I'm using GET_DATA etc. and getting back delayed quotes/prices/... What do I need to do to get real
Best Answer
-
You can use the following statement to get your constituents:
option_chain,err = ek.get_data('0#SPX*.U', ['CF_NAME'])
And to get your real-time data, try something like this: (Note: The Pricing interface / WebSocket service has a limitation when making a single request - so you will have to break up the request into buckets - in the example below, I'm using a value of 100).
0
Answers
-
If you want to get real-time data, I would suggest you look at the pricing cache example which subscribes to data and allows the ability to pull out live data from the cache.
0 -
Currently I use:
option_chain, err = ek.get_data('0#SPX*.U', ['TRADE_DATE', 'ACVOL_1'])
option_data_block, err = ek.get_data(instruments =option_chain['Instrument'].tolist(), fields=['PUTCALLIND', 'TRDPRC_1', 'BID', 'ASK', 'TRADE_DATE', 'SALTIM', 'STRIKE_PRC', 'EXPIR_DATE'])
undelying_price, err = ek.get_data('.SPX', ['CF_LAST'])
Are you saying Nick that I can not use those 3 statements to get real time option data and the price of underlying?
0 -
I need to get those field real time !!!!
0 -
How do I do that?0
-
I'm doing that already Nick, that's why I provided the code !!!! The issue I'm having is that the data I get back is delayed and I want it real time !!!! What do I need to do to get real time data using that code????? Thanks0
-
Oh sorry, its different code that you modified, I missed that stream thing. Thanks so much, I will try it.0
-
Nick,
I need Web Socket Service for this as I understand, is that correct? That's a separate subscription that I need to get, right? I do no have Refinitiv library to do
from refinitiv.data.content import pricing
I just have Eikon library
Thanks so much for your help
0 -
The refinitiv.data library should be available to you. You can refer to the learning material on our dev portal for more details: Refinitiv Data Library for Python. I believe you should have streaming services as part of your license - I would try one of the basic tutorials within the link I provided.
0 -
Also, you can try one of the pricing examples within CodeBook - under the __Examples__ folder, you can navigate down to many examples - the one I'm referring to is: EX_01_01_11_Content_Pricing_Streaming. If you can successfully execute that example, you are good to go.0
-
Thank you sir for those last 2 messages. I really appreciate it. As long as I can do from refinitiv.data.content import pricing
I should be fine. May have to install that package. I'll try it tomorrow and let you know. We have your data company wide, we dropped Bloomberg so I would think I have license needed.
0 -
Hi Nick,
1 last question. I also need to get weekly SPX option chain. Its about 13,000 items. When I run:
option_chain, err = ek.get_data('0#SPXW*.U', ['CF_NAME'])
it times out. What options do I have to get weekly SPX option chain? Can I use a filter to pull only a subset of them?
Thanks so much Nick
0 -
Hi @vlad.dimanshteyn
Does the request to retrieve this option chain always fail? I don't know if it may fall into the category of data limits or if there is a backend issue. I think it would be best if you were to post this as a separate question as I think it will involve more than a few comments here :-). Thanks.
0
Categories
- All Categories
- 6 AHS
- 39 Alpha
- 161 App Studio
- 4 Block Chain
- 4 Bot Platform
- 16 Connected Risk APIs
- 47 Data Fusion
- 30 Data Model Discovery
- 608 Datastream
- 1.3K DSS
- 577 Eikon COM
- 4.9K Eikon Data APIs
- 7 Electronic Trading
- Generic FIX
- 7 Local Bank Node API
- Trading API
- 2.7K Elektron
- 1.3K EMA
- 236 ETA
- 519 WebSocket API
- 33 FX Venues
- 10 FX Market Data
- 1 FX Post Trade
- 1 FX Trading - Matching
- 12 FX Trading – RFQ Maker
- 5 Intelligent Tagging
- 2 Legal One
- 20 Messenger Bot
- 2 Messenger Side by Side
- 9 ONESOURCE
- 7 Indirect Tax
- 59 Open Calais
- 264 Open PermID
- 39 Entity Search
- 2 Org ID
- PAM
- PAM - Logging
- 8.4K Private Comments
- 6 Product Insight
- Project Tracking
- ProView
- ProView Internal
- 20 RDMS
- 1.4K Refinitiv Data Platform
- 370 Refinitiv Data Platform Libraries
- 3 Refinitiv Due Diligence
- LSEG Due Diligence Portal API
- 3 Refinitiv Due Dilligence Centre
- Rose's Space
- 1.1K Screening
- 18 Qual-ID API
- 13 Screening Deployed
- 23 Screening Online
- 10 World-Check Customer Risk Screener
- 990 World-Check One
- 44 World-Check One Zero Footprint
- 45 Side by Side Integration API
- Test Space
- 3 Thomson One Smart
- 1.2K TR Internal
- Global Hackathon 2015
- 2 Specialists Who Code
- 10 TR Knowledge Graph
- 150 Transactions
- 142 REDI API
- 1.7K TREP APIs
- 4 CAT
- 21 DACS Station
- 117 Open DACS
- 1.1K RFA
- 103 UPA
- 172 TREP Infrastructure
- 224 TRKD
- 886 TRTH
- 5 Velocity Analytics
- 5 Wealth Management Web Services
- 60 Workspace SDK
- 9 Element Framework
- 5 Grid
- 13 World-Check Data File
- Yield Book Analytics
- 46 中文论坛