
BTC on 5-minute bars in the 0xArchive Terminal, 2026-10-15.
Open on a chart
Load it on BTC 5m in the terminal, then change its settings or open it in the script editor.
How it works
A tally adds each trade as it arrives. The running total isstate.bar, added to in onClose, so the forming bar shows the total so far without adding it twice: every update of the forming bar starts again from the last closed bar.
The script
cvd.ts