Getting problem for calculation of volume from websocket data feed for perticular candles guide me for this and also clarity that the websocket feed sending cumulative traded volumes or incremental volumes for each tick…? Need to calculate volume for 1 min candle on websocket…
I was trying to figure out the same. But after a bit of hit and trial here is what I have found.
- Volume are cumulative
- To get volume for specific tick, we need to subtract from previous tick value.
I have written an implementation in dotnet which seems to be working with 99.9% value accuracy, but when I compare with values on upstox, it’s off by 0.5% occasionally.
An official conformation would be very helpful.
1 Like
Yaa.thanks,i tried that approach of subtraction but still not getting accurate volume numbers (may be due to missing bits sometimes)