Skip to main content
Source: src/Data/LiveDelta.cs · Calculated on: desktop or server The delta of every bar, ask volume minus bid volume, as a histogram. Add it in an area of its own: its values are volumes.

What it shows

  • OnTick in realtime.
  • The totals of a bar, VolTotList[0].
  • History from the bars, realtime from the trades.
  • Options of the Y axis.

Two sources for the same value

The history comes from the totals of each closed bar:
The bar in progress is built trade by trade:
with the trades asked for realtime only:
This is what keeps the indicator portable: asking for the trades of the history (HistRT) would make it a desktop one.

The Y axis

Things to notice

  • OnOpen resets liveDelta: the counter belongs to the bar in progress.
  • With MinimumSize above 1 the closed bar keeps the value built from the trades, because the totals of a bar have no size filter. On the history that filter cannot be applied: closed bars of the history always show the full delta.

Try

  • Add the cumulative delta of the session as a second series.
  • Color the bars by whether the delta agrees with the direction of the price.