MID_PRICE discrepancy between Excel & Python API
For the 6pm Malta FX, below is the code:
rd.get_history(fx_list, ['MID_PRICE'], interval='minute', end=this_date, count=1)
Generally, this is working and we are getting the same rates EXCEPT for a few instances, and I would like to know why there are these differences
=RHistory($B$3:NQ$3,"MID_PRICE.Timestamp;MID_PRICE.Close","END:"&$V$2+$F$1&" TIMEZONE:"&H$1&" INTERVAL:1M NBROWS:1",,"TSREPEAT:NO SORT:ASC")
Tried RDP in RW and CODEBOOK but not able to replicate
Best Answer
-
Sorry for the issue you are facing, let me see if I can help you in resolving this.
RDP returns data in GMT and you specify CET in the RHistory function. On 17 Oct 2022, CET is two hours ahead of GMT (CET = GMT + 2:00),
Therefore, the GMT time for CET 18:00 on 17 Oct 2022 is 16:00.
rd.get_history(["EURNOK="], ['MID_PRICE'], interval='minute', end="2022-10-17T16:05:00", count=10)
The output is:
The value 10.3476 shows at 15:59:00 because it uses the startPeriod as the default of the summaryTimestampLabel parameter.
The summaryTimestampLabel parameter controls the timestamp label in the response to be either at the start summarization period or at the end of summarization period. The parameter is available in the intraday-summaries and interday-summaries APIs and its possible values are as follows:
- startPeriod indicates that the data returned is labelled at the start of summarization period.
- endPeriod indicates that the data returned is labelled at the end of summarization period.I checked can found that the get_history function doesn't procide a paramter to change the value of the summaryTimestampLabel parameter so to change its value you need to use the historical pricing example instead (Content__Historical_Pricing.ipynb).
response = historical_pricing.summaries.Definition(
universe = "EURNOK=",
interval = Intervals.ONE_MINUTE,
count = 10,
fields=["MID_PRICE"],
end ="2022-10-17T16:05:00Z",
extended_params={"summaryTimestampLabel":"endPeriod"}
).get_data()
response.data.dfThe output is:
I hope this will help.
0
Categories
- All Categories
- 6 AHS
- 37 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
- 367 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
- 59 Workspace SDK
- 9 Element Framework
- 5 Grid
- 13 World-Check Data File
- Yield Book Analytics
- 46 中文论坛