Support Board
Date/Time: Fri, 23 Oct 2026 04:56:17 +0000
Post From: Supported method for a read-only 30-second volatility meter on Range Bar charts
| [2026-09-09 03:03:03] |
| dav19e - Posts: 5 |
|
Not support, just another user who's spent a lot of time in ACSIL. On 2: sc.GetTimeAndSales() is right, but you don't need to track the sequence numbers yourself. c_SCTimeAndSalesArray already does it: GetSequenceNumberOfLastElement() — store this at the end of each pass ValidateAndCorrectPriorSequenceNumber(uint32_t&) — call it first on the next pass. It handles the sequence resetting or wrapping, which otherwise leaves you silently processing nothing GetRecordIndexAtGreaterThanSequenceNumber(seq) — binary search, gives you where to start reading That gets you everything since your last call without scanning the array. Filter on Type == SC_TS_BID or SC_TS_ASK for executed trades; SC_TS_BIDASKVALUES is quote updates, not trades. On 3: sc.GetTimeSalesArrayIndexesForBarIndex(BarIndex, r_BeginIndex, r_EndIndex) maps a bar to its slice of the time and sales array, which is usually less work than going to the SCID file. But it only covers what's currently in that array, so for a restart or for Chart Replay you'll still need sc.ReadIntradayFileRecordForBarIndexAndSubIndex() against 1-tick data. One more: run this with sc.AutoLoop = 0. A rolling wall-clock window has nothing to do with bar boundaries, and most sample code you'll find assumes auto-loop. Leaving 1 to Engineering. |
