Support Board
Date/Time: Sun, 29 Dec 2024 16:18:04 +0000
Date time accuracy during replay using sc.CurrentDateTimeForReplay
View Count: 1091
[2016-04-29 14:59:45] |
@sstfrederik - Posts: 404 |
Hi. I am using sc.CurrentDateTimeForReplay, but it is not behaving as expected. Not sure if that can be changed. My intent is to get accurate bartime information during a replay. I expect NcurrentBarTime to "see" every second. Instead its skipping based on the start the replay and replay speed selected. Which is what the documentation says. This is not very useful when I want to execute some code at exactly 10:00:00 during a reply. This time will likely be skipped. Any chance to have a different implementation of sc.CurrentDateTimeForReplay? Thanks. if(sc.IsReplayRunning()){ SCDateTime NcurrentBarTime = sc.CurrentDateTimeForReplay; } |
[2016-04-29 15:24:15] |
Sierra Chart Engineering - Posts: 104368 |
You need to use this: https://www.sierrachart.com/index.php?page=doc/doc_ACSIL_Members_Variables_And_Arrays.html#scUpdateAlways Sierra Chart Support - Engineering Level Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy: https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service: Sierra Chart Teton Futures Order Routing |
[2016-04-29 16:00:11] |
@sstfrederik - Posts: 404 |
I am using sc.UpdateAlways Some of the message log output to show there is some skipping. Chart: Replay 5.0X: GCM16 1 Min #1 | Study: Break out strategy | NcurrentBarTime = 20.04.2016 09 : 55 : 37 currentBarTime = 35737, StartTime = 36000 | 2016-04-29 11:55:33 * Chart: Replay 5.0X: GCM16 1 Min #1 | Study: Break out strategy | NcurrentBarTime = 20.04.2016 09 : 55 : 37 currentBarTime = 35737, StartTime = 36000 | 2016-04-29 11:55:33 * Chart: Replay 5.0X: GCM16 1 Min #1 | Study: Break out strategy | NcurrentBarTime = 20.04.2016 09 : 55 : 37 currentBarTime = 35737, StartTime = 36000 | 2016-04-29 11:55:33 * Chart: Replay 5.0X: GCM16 1 Min #1 | Study: Break out strategy | NcurrentBarTime = 20.04.2016 09 : 55 : 37 currentBarTime = 35737, StartTime = 36000 | 2016-04-29 11:55:33 * Chart: Replay 5.0X: GCM16 1 Min #1 | Study: Break out strategy | NcurrentBarTime = 20.04.2016 09 : 55 : 40 currentBarTime = 35740, StartTime = 36000 | 2016-04-29 11:55:34 * Chart: Replay 5.0X: GCM16 1 Min #1 | Study: Break out strategy | NcurrentBarTime = 20.04.2016 09 : 55 : 40 currentBarTime = 35740, StartTime = 36000 | 2016-04-29 11:55:34 * Chart: Replay 5.0X: GCM16 1 Min #1 | Study: Break out strategy | NcurrentBarTime = 20.04.2016 09 : 55 : 42 currentBarTime = 35742, StartTime = 36000 | 2016-04-29 11:55:34 * Chart: Replay 5.0X: GCM16 1 Min #1 | Study: Break out strategy | NcurrentBarTime = 20.04.2016 09 : 55 : 42 currentBarTime = 35742, StartTime = 36000 | 2016-04-29 11:55:34 * Chart: Replay 5.0X: GCM16 1 Min #1 | Study: Break out strategy | NcurrentBarTime = 20.04.2016 09 : 55 : 45 currentBarTime = 35745, StartTime = 36000 | 2016-04-29 11:55:35 * |
[2016-04-29 21:31:42] |
Sierra Chart Engineering - Posts: 104368 |
Make sure the chart update interval for the chart is under one second.
Sierra Chart Support - Engineering Level Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy: https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service: Sierra Chart Teton Futures Order Routing |
[2016-04-30 13:23:26] |
@sstfrederik - Posts: 404 |
I double checked but it is at 500 ms, default setting. Skipping starts from replayspeeds of 3 and higher. Date Time Of Last Edit: 2016-04-30 13:29:37
|
[2016-04-30 18:08:32] |
Sierra Chart Engineering - Posts: 104368 |
Then there must be other processing going on, maybe the reading the data file or other charts which are updating which is causing delays. You will have to determine the reason and solve it. Refer to help topic 30: https://www.sierrachart.com/index.php?l=helpdetails30.html Sierra Chart Support - Engineering Level Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy: https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service: Sierra Chart Teton Futures Order Routing |
[2016-04-30 18:12:04] |
Sierra Chart Engineering - Posts: 104368 |
But we will test this to see if it is working as expected.
Sierra Chart Support - Engineering Level Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy: https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service: Sierra Chart Teton Futures Order Routing |
[2016-04-30 18:30:31] |
Sierra Chart Engineering - Posts: 104368 |
We are looking this over. One question we have is are you replaying multiple charts and using Accurate Trading System Back Test Mode on the replay window?
Sierra Chart Support - Engineering Level Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy: https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service: Sierra Chart Teton Futures Order Routing |
[2016-04-30 18:47:33] |
Sierra Chart Engineering - Posts: 104368 |
We have made some small changes that might help with this. Wait for the next release. Sierra Chart Support - Engineering Level Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy: https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service: Sierra Chart Teton Futures Order Routing |
[2016-04-30 19:24:56] |
@sstfrederik - Posts: 404 |
I will wait for the next release. I am replaying a single chart with Accurate Trading System Back Test Mode.Thanks for looking into this.
Date Time Of Last Edit: 2016-04-30 19:25:13
|
[2016-05-04 01:28:51] |
@sstfrederik - Posts: 404 |
I just installed 1405 pre-release, but see no change. Was the change present in 1405? Or do I need to wait for the next current version? thanks |
[2016-05-04 02:46:48] |
Sierra Chart Engineering - Posts: 104368 |
Yes it is part of that release and we did not think it would make any difference anyway. We do not see how we can offer further help with this. We noticed you said this: Skipping starts from replayspeeds of 3 and higher. That very well could be. We would have to examine specifically why this is the case but thinking about it, it does make sense. Anyway, we cannot help with this. Sierra Chart Support - Engineering Level Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy: https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service: Sierra Chart Teton Futures Order Routing Date Time Of Last Edit: 2016-05-04 14:28:55
|
[2016-05-04 10:08:29] |
@sstfrederik - Posts: 404 |
So you are not going to adjust the function? Maybe adjust the documentation than. Also that this function can not be used in a replay backtest. This function is fine for a regular speed replay, but I doubt many users will want to use it for that.
|
[2016-05-04 14:25:09] |
Sierra Chart Engineering - Posts: 104368 |
This is not a function. It is a variable. You are relying on it for a purpose which it was not designed for. But it goes further than that, you are relying upon the study function to be called every theoretical second during an accelerated replay. This is simply not supported by Sierra Chart. We are not sure what the documentation should say. When the study function is called, sc.CurrentDateTimeForReplay certainly does indicate the correct replay time. This is the first time in the history of Sierra Chart this has ever come up. Sierra Chart Support - Engineering Level Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy: https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service: Sierra Chart Teton Futures Order Routing Date Time Of Last Edit: 2016-05-04 14:25:50
|
[2016-05-04 14:40:12] |
@sstfrederik - Posts: 404 |
I am not aware of your history. Just indicating that the variable can not be used for time accuracy during higher speed replays. that is what could be said in the documentation. Its clear to me that SC does not support this requirement. I just want to test time based entries and exits independent of chartdata and chartsettings. In live environment this can be done with systemtime variable, but in replay mode this can not be tested at high speeds. |
[2016-05-04 15:46:11] |
Sierra Chart Engineering - Posts: 104368 |
Thinking about this some more, if you reduce the Chart >> Chart Settings >>Advanced Settings >> Chart Update Interval in proportion to the replay speed, then this might solve the problem. For example if you are replaying the chart at 10 times, then use a 100 millisecond Chart Update Interval. However, this is only going to work with replay speeds that do not go too high. If you are replaying at 100 times or more, then there is no update interval which is going to be fast enough and reliably work. Although the thing is, the Chart Update Interval is automatically reduced during an accelerated replay anyway so this may not make any difference. Sierra Chart Support - Engineering Level Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy: https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service: Sierra Chart Teton Futures Order Routing Date Time Of Last Edit: 2016-05-04 15:50:18
|
To post a message in this thread, you need to log in with your Sierra Chart account: