¿ªÔÆÌåÓý

ctrl + shift + ? for shortcuts
© 2025 Groups.io

API historical data with less decimals than seen in chart for EUR.USD


 

Gents,

I am comparing the historical data response received through an API request with data shown on TWS chart, and notice that the API data has less decimals than the data shown on the chart.
For example, below is an line from the API response (the request was for 5 second bars):

2023-02-06 21:30:56,029 INFO? - IB -> HistoricalData -> requestId=[65], time=[20230206? 14:30:00], open=[1.07355], high=[1.07355], low=[1.0735], close=[1.0735], volume=[-1], wap=[-1.0], count=[-1], hasGaps=[false]

On the chart on the other hand I see high=1.07353, low=1.07349, close=1.07349

It seems that the API response is rounding the values to 0.00005 which is also the minTick published in the contract details.

Is there a way to get the exact same values as displayed on the chart? Why is the API rounding the values?


Join [email protected] to automatically receive all group messages.