开云体育

ctrl + shift + ? for shortcuts
© 2025 开云体育

is reqHistoricalData() returning partial trade bars?


 

Hi,

I seem to be witnessing the following behaviour: if I request historical data with a timestamp?that is not aligned with the trade bar size I'm requesting, the last trade bar will be a partial trade bar, 'up to' the requested timestamp. Is this a correct assumption?

To be a bit specific, for example requesting 2 minute trade bars with an endDateTime of 15:02:30 will return a trade bar for 15:02:00 but contain data only for the half minute period between 15:02:00 - 15:02:30.

An alternative would be that the API only returns complete trade bars, which?seems not to be the case.


?kos


 

It returns partial bars for daily bars. So if you request including today during the ongoing trading session the last bar will be for today until the current moment. So I'd assume it does the same for 2min bars.