Login Page - Create Account

Support Board


Date/Time: Wed, 30 Apr 2025 11:09:37 +0000



Post From: Accessing `NumOrders` During Market Depth Replay from Historical Data

[2025-04-19 17:45:59]
Thanthou - Posts: 6
Hello Sierra Chart Team,

I’ve been working with the historical `.depth` files available through your data services, and I’ve noticed that these files clearly include the number of orders (`NumOrders`) along with quantity and price at each depth level. I’ve confirmed this by unpacking the binary structure directly (e.g., via Python using `struct.unpack('qbbhfII', ...)`).

However, during a chart replay using `sc.GetAskMarketDepthEntryAtLevel()` and `sc.GetBidMarketDepthEntryAtLevel()`, the `NumOrders` field is always reported as zero — even though quantity and price are populated correctly.

Could you clarify:

1. Is this the expected behavior — i.e., `NumOrders` is not loaded during market depth replay even if it exists in the `.depth` file?
2. If so, is there any current or planned way to access the historical `NumOrders` during replay (perhaps via internal APIs or through an alternative study)?
3. If not currently supported, would it be feasible to request that `NumOrders` be surfaced during replay for more complete reconstruction of historical depth?

Thank you for your time and your excellent platform.