Support Board
Date/Time: Wed, 12 Feb 2025 01:31:30 +0000
Post From: Where does the sc.Index, sc.CurrentIndex indexing start?
[2020-09-24 17:40:49] |
mbilyanov - Posts: 62 |
I understand this is an index used for autolooping etc. ...
current sc.Index value is 0 data[sc.Index] Same as data[0] current sc.Index value is 1 data[sc.Index] Same as data[1] current sc.Index value is 2 data[sc.Index] Same as data[2] ... On a 1 min chart, 16:00:00 - 16:59:59 is being displayed and the time now is 16:59:57 so the last bar is still being drawn, we have not finished 16:59:59 and moved into 17:00:00 So the bars are like the following, from left to right: > 16:00:00-16:00:59 > 16:01:00-16:01:59 > 16:02:00-16:02:59 ... ... ... > 16:57:00-16:57:59 > 16:58:00-16:58:59 > 16:59:00-16:59:59 -- latest bar still drawing. So is index 0 the most outer bar or data slice on the right side? The newest? The one at 16:59:59, the one that is still being painted and not closed yet? Or is it he most outer data slice on the left side (let's say 16:00:00-16:00:59) |