Support Board
Date/Time: Sat, 11 Jan 2025 00:38:16 +0000
Post From: Renko bar in ticks; missing arraysize adjustment
[2016-10-10 14:32:21] |
@sstfrederik - Posts: 404 |
I am working on a strategy that uses a chart with "Renko Bar (in ticks)". I have noticed that there can be occasions that the sc.Index is adjusted, but the sc.ArraySize is not. I am basing some calculations on the close of the last bar when sc.ArraySize is incremented. if (PriorArraySize < sc.ArraySize){ SCString aap; aap.Format("sc.Index = %d, RenkoClose[sc.Index] = %f, LatestLow =%f",sc.Index,RenkoClose[sc.Index],LatestLow); sc.AddMessageToLog(aap,1); } PriorArraySize = sc.ArraySize; sc.UpdateAlways = 1; I have some output on a very basic study that shows this. sc.Index is raised from 26371 to 26372 while sc.ArraySize is not incremented. Am I missing something here? Thanks for your time. Chart: Replay 1.0X: GBPUSD [M] Renko 3t #1 | Study: Strategy | sc.Index = 26370, RenkoClose[sc.Index] = 1.240405, PriorArraySize = 26371, sc.ArraySize = 26371 | 2016-10-10 10:08:26 * Chart: Replay 1.0X: GBPUSD [M] Renko 3t #1 | Study: Strategy | sc.Index = 26370, RenkoClose[sc.Index] = 1.240405, PriorArraySize = 26371, sc.ArraySize = 26371 | 2016-10-10 10:08:26 * Chart: Replay 1.0X: GBPUSD [M] Renko 3t #1 | Study: Strategy | sc.Index = 26370, RenkoClose[sc.Index] = 1.240600, PriorArraySize = 26371, sc.ArraySize = 26373 | 2016-10-10 10:08:27 * Chart: Replay 1.0X: GBPUSD [M] Renko 3t #1 | Study: Strategy | sc.Index = 26370, RenkoClose[sc.Index] = 1.240600, LatestLow = 1.240300 | 2016-10-10 10:08:27 * Chart: Replay 1.0X: GBPUSD [M] Renko 3t #1 | Study: Strategy | sc.Index = 26371, RenkoClose[sc.Index] = 1.240750, PriorArraySize = 26373, sc.ArraySize = 26373 | 2016-10-10 10:08:27 * Chart: Replay 1.0X: GBPUSD [M] Renko 3t #1 | Study: Strategy | sc.Index = 26372, RenkoClose[sc.Index] = 1.240775, PriorArraySize = 26373, sc.ArraySize = 26373 | 2016-10-10 10:08:27 * Chart: Replay 1.0X: GBPUSD [M] Renko 3t #1 | Study: Strategy | sc.Index = 26372, RenkoClose[sc.Index] = 1.240775, PriorArraySize = 26373, sc.ArraySize = 26373 | 2016-10-10 10:08:27 * Chart: Replay 1.0X: GBPUSD [M] Renko 3t #1 | Study: Strategy | sc.Index = 26372, RenkoClose[sc.Index] = 1.240775, PriorArraySize = 26373, sc.ArraySize = 26373 | 2016-10-10 10:08:27 * Chart: Replay 1.0X: GBPUSD [M] Renko 3t #1 | Study: Strategy | sc.Index = 26372, RenkoClose[sc.Index] = 1.240820, PriorArraySize = 26373, sc.ArraySize = 26373 | 2016-10-10 10:08:28 * Chart: Replay 1.0X: GBPUSD [M] Renko 3t #1 | Study: Strategy | sc.Index = 26372, RenkoClose[sc.Index] = 1.240820, PriorArraySize = 26373, sc.ArraySize = 26373 | 2016-10-10 10:08:28 * Chart: Replay 1.0X: GBPUSD [M] Renko 3t #1 | Study: Strategy | sc.Index = 26372, RenkoClose[sc.Index] = 1.240820, PriorArraySize = 26373, sc.ArraySize = 26373 | 2016-10-10 10:08:28 * Chart: Replay 1.0X: GBPUSD [M] Renko 3t #1 | Study: Strategy | sc.Index = 26372, RenkoClose[sc.Index] = 1.240450, PriorArraySize = 26373, sc.ArraySize = 26374 | 2016-10-10 10:08:29 * Chart: Replay 1.0X: GBPUSD [M] Renko 3t #1 | Study: Strategy | sc.Index = 26372, RenkoClose[sc.Index] = 1.240450, LatestLow = 1.240300 | 2016-10-10 10:08:29 * Chart: Replay 1.0X: GBPUSD [M] Renko 3t #1 | Study: Strategy | sc.Index = 26373, RenkoClose[sc.Index] = 1.240370, PriorArraySize = 26374, sc.ArraySize = 26374 | 2016-10-10 10:08:29 * Chart: Replay 1.0X: GBPUSD [M] Renko 3t #1 | Study: Strategy | sc.Index = 26373, RenkoClose[sc.Index] = 1.240370, PriorArraySize = 26374, sc.ArraySize = 26374 | 2016-10-10 10:08:29 * |