¿ªÔÆÌåÓý

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

Re: Level2 data falls behind actual market


 

Outside RTH it stays in sync no issues.? Only during RTH is the issue.

On Wed, Aug 9, 2023 at 7:13 PM Gordon Eldest via <hymagik=[email protected]> wrote:

Look to me like the Highest Bid and Lowest Ask. They are unrealized transaction.
They are reported in the callbacks, "I am sure of it."
How you compare it is the issue, if you display TWS in // to a SQL SELECT, definitively it's move too fast to be insync, you may even have TWS late to the API, but your DB is most probably the reference, or you should investigate your INSERT timing. (you better bulk it in a separate thread)

If you want to make a visual inspection, don't use the [0] but someplace deeper, like around the 20th row or with 0.25% <> to top, they change less frequently as they are more "fishing" position and any better bid or more aggressive ask may insert above but faster.
Or take a stock that not aggressively traded, low daily volume typically.
Or take a look at it outside RTH, market are way slower.
Or don't use a DB but a memory Map and dump it,
etc ....
Trust the API and dig elsewhere.

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