Discover Refinitiv
MyRefinitiv Refinitiv Perspectives Careers
Created with Sketch.
All APIs Questions & Answers  Register |  Login
Ask a question
  • Questions
  • Tags
  • Badges
  • Unanswered
Search:
  • Home /
  • Eikon Data APIs /
avatar image
Question by dayquant · Aug 13, 2019 at 07:02 AM · eikon apiclosepricepython-api

Close Price Not Available

Hi,

It is Aug 13, 2019, 4:30 pm IST now and I am trying to download close price for couple of Indian RICs `TCS.NS` and `HDBK.NS` since it has been end of trading hours for Indian market (3:30 pm IST).

Usually everyday by this time, the close price gets downloaded via Excel or Python API, but today I am unable to retrieve them.

Please see my below code and corresponding output.

import eikon as ek
rics = ['HDBK.NS', 'TCS.NS']
fields = [ek.TR_Field('TR.PriceClose'), ek.TR_Field('TR.PriceClose.date')]
df = ek.get_data(instruments=rics, fields=fields, parameters={'SDate': '2019-08-08', 'EDate': '2019-08-13', 'FRQ': 'D', 'CH': 'Fd;IN', 'RH': 'date', 'SORTD': 'date'})
print(df)

Output is as follows:

(  Instrument  Price Close                  Date
0    HDBK.NS      2233.15  2019-08-08T00:00:00Z
1    HDBK.NS      2282.00  2019-08-09T00:00:00Z
2    HDBK.NS      2282.00  2019-08-09T00:00:00Z
3     TCS.NS      2258.10  2019-08-08T00:00:00Z
4     TCS.NS      2246.25  2019-08-09T00:00:00Z
5     TCS.NS      2246.25  2019-08-09T00:00:00Z, None)

Note that the price downloaded is for Aug 8 and 9, not Aug 13.

Any help would be appreciated.

People who like this

0 Show 0
Comment
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

3 Replies

  • Sort: 
avatar image
REFINITIV
Best Answer
Answer by chavalit.jintamalit · Aug 13, 2019 at 07:35 AM

Hi @dayquant

Because the historical database is not ready yet (it takes some time)

You can retrieve today close price from "Intraday" fields.


ahs-updated.png (8.2 KiB)
Comment

People who like this

0 Show 1 · Share
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

avatar image
dayquant · Aug 13, 2019 at 11:12 PM 0
Share

Thanks for the answer.

Can you help me with understanding the difference between these fields?

  • TR.PriceClose
  • TR.ClosePrice
  • OFF_CLOSE
  • TR.OFFICIALCLOSEPRICE
  • CF_CLOSE

I am looking for 30-min closing (end of day) VWAP price. Which of the above should I use?

avatar image
REFINITIV
Answer by jason.ramchandani · Aug 13, 2019 at 08:43 AM

Hi @dayquant The figures from chavalit above are in fact the previous days close (ie 9th)

I have just run the code and it has correctly delivered the results.

The only reason I can think of is there was some delay with closing run process of that exchange today. Im not sure if this can help - but please observe it tomorrow again. If there is a similar issue we can investigate further.


screenshot-2019-08-13-at-134209.png (91.0 KiB)
Comment

People who like this

0 Show 2 · Share
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

avatar image
dayquant · Aug 13, 2019 at 11:08 PM 0
Share

Thanks for the answer.

Can you help me with understanding the difference between these fields?

  • TR.PriceClose
  • TR.ClosePrice
  • OFF_CLOSE
  • TR.OFFICIALCLOSEPRICE
  • CF_CLOSE

I am looking for 30-min closing (end of day) VWAP price. Which of the above should I use?

avatar image
REFINITIV
chavalit.jintamalit ♦♦ dayquant · Aug 14, 2019 at 03:45 AM 0
Share

Hi @dayquant

You can use "Data Item Browser" to see each of the field description.

Please type in "DIB" (without double quotes) on the Eikon Desktop search bar and press enter.

Then input the instrument code and field name.

The fields you provided are from 3 different databases:

For example TR.PRICECLOSE is on "Prine & Volume" database.

OFF_CLOSE and CF_CLOSE are on "Real Time" database.

TR.ClosePrice and TR.OFFICIALCLOSEPRICE are on "Time Series Data" database.

If the Data Item Browser does not provide enough information on each fields, you can contact Refinitiv Content Support at https://my.refinitiv.com/

ahs.png (128.9 KiB)
ahs2.png (155.6 KiB)
avatar image
REFINITIV
Answer by chavalit.jintamalit · Aug 13, 2019 at 09:38 AM

Sorry I would like to update my answer a bit.

CF_CLOSE of today is the previous trading day CLOSE (which @jason.ramchandani pointed out, thanks.)

CF_<xx> fields are on realtime data set, while TR.PriceClose is on a time series dataset.

It usually takes some time before the data is ready in time series dataset.

So you have to use "CF_LAST" field for today last price like you experienced it yourselves that the data was not ready yet and you could not retrieve it using TR.PriceClose field.

Comment

People who like this

0 Show 0 · Share
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Watch this question

Add to watch list
Add to your watch list to receive emailed updates for this question. Too many emails? Change your settings >
10 People are following this question.

Related Questions

How can I retrieve historical total shares outstanding & total market cap for a spesific equity/index?

Eikon API: Earnings Releases

Old ISIN does not fetch RIC code

Vessel Characteristics

Identify characteristics of historic board members on ASX 200 companies?

  • Feedback
  • Copyright
  • Cookie Policy
  • Privacy Statement
  • Terms of Use
  • Careers
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Alpha
  • App Studio
  • Block Chain
  • Bot Platform
  • Calais
  • Connected Risk APIs
  • DSS
  • Data Fusion
  • Data Model Discovery
  • Datastream
  • Eikon COM
  • Eikon Data APIs
  • Elektron
    • EMA
    • ETA
    • WebSocket API
  • Legal One
  • Messenger Bot
  • Messenger Side by Side
  • ONESOURCE
    • Indirect Tax
  • Open PermID
    • Entity Search
  • Org ID
  • PAM
    • PAM - Logging
  • ProView
  • ProView Internal
  • Product Insight
  • Project Tracking
  • Refinitiv Data Platform
    • Refinitiv Data Platform Libraries
  • Rose's Space
  • Screening
    • Qual-ID API
    • Screening Deployed
    • Screening Online
    • World-Check One
    • World-Check One Zero Footprint
  • Side by Side Integration API
  • TR Knowledge Graph
  • TREP APIs
    • CAT
    • DACS Station
    • Open DACS
    • RFA
    • UPA
  • TREP Infrastructure
  • TRIT
  • TRKD
  • TRTH
  • Thomson One Smart
  • Transactions
    • REDI API
  • Velocity Analytics
  • Wealth Management Web Services
  • World-Check Data File
  • Explore
  • Tags
  • Questions
  • Badges