I am using the Data Recorder API to record trades, quotes, BBO etc. in a text file.
When I am looking at the "Quote"-lines that are recorded I see a difference to what is displayed in Bookmap (in the heat map).
API Code (kept in standard from Git) of the data recorder:
Code: Select all
@Override public void onDepth(boolean isBid, int price, int size) {
String side = isBid ? "Buy" : "Sell";
writeObjects("Quote", side, price, size);
}
Output for todays ESZ0 price level 3403 since the beginning of my recording (UTC/GMT +1:00 hour):
(date, type, price, direction, volume)
2020-09-15 06:39:23.280432,Quote,3403.0,Sell,19
2020-09-15 07:12:20.874939,Quote,3403.0,Sell,21
2020-09-15 07:12:20.874939,Quote,3403.0,Sell,21
2020-09-15 07:52:32.571009,Quote,3403.0,Sell,20
2020-09-15 07:52:32.571009,Quote,3403.0,Sell,20
2020-09-15 08:08:58.325661,Quote,3403.0,Sell,21
2020-09-15 08:08:58.325661,Quote,3403.0,Sell,21
2020-09-15 08:14:35.747663,Quote,3403.0,Sell,20
2020-09-15 08:14:35.747663,Quote,3403.0,Sell,20
2020-09-15 08:21:55.284038,Quote,3403.0,Sell,21
2020-09-15 08:21:55.284038,Quote,3403.0,Sell,21
2020-09-15 08:44:56.401192,Quote,3403.0,Sell,20
2020-09-15 08:44:56.401192,Quote,3403.0,Sell,20
And what is displayed in Bookmap:
In Bookmap the volume of this pricelevel is above what is recorded in the API (at around 120 vs 30). This problem occurs for alle price levels so I assume there is some calculation logic to be known. I would like to have the correct volumes of the order book recorded.
Where is the difference coming from?
How are the Quotes/ the volume in the DOM calculated in Bookmap?
How can I fix it?
Thank you
Best
Philipp