Login Page - Create Account

Support Board


Date/Time: Thu, 02 May 2024 19:03:11 +0000



[User Discussion] - Zig Zag Alerts

View Count: 1256

[2019-09-13 22:48:22]
Chris_uk - Posts: 89
Hi,

I am using the Spreadsheet System/Alert Study to create alerts based off the Zig Zag Study. I am not sure if what I am experiencing is normal behaviour, or if It's an error on my part.

Zig Zag Study = ID8

Column R = Reversal Price =IF(ID8.SG3@3>0,ID8.SG3@3,R4)
Column S = Reversal Price -1 =IF(ID8.SG3@3>0,R4,S4)
Column T = Reversal Price -2 =IF(ID8.SG3@3>0,S4,T4)

Column U = Text Labels =IF(ID8.SG2@3>0,ID8.SG2@3,U4)
Column V = Text Labels -1 =IF(ID8.SG2@3>0,U4,V4)
Column W = Text Labels -2 =IF(ID8.SG2@3>0,V4,W4)

Column K(row 3)Buy Entry =AND(W3=2, E3 > T3)

So I would like an alert when:

Text label[-2] = 2(HH)
Current Bars close > Reversal Price[-2]

This does work some of the time, at other times alerts are displayed and then later disappear, their values in the spreadsheet change from TRUE TO FALSE.

I have read this, but it only explains some of what I am seeing in this case.

Spreadsheet Systems, Alerts and Automated Trading: Disappearing Arrows or Signals

After watching the spreadsheet during many replays I have identified what I believe to be the cause.

Values in prior cells are changing at a later time (This is happening when a new swing has not started)

Example:

1 Minute Chart

18:44:00 = New Swing Starts
18:44:00 = W3 =2 (TEXT LABEL[-2])
18:44:00 = T3 = 3019.25 (Reversal price[-2])
Close Above T3 Alert Triggered

18:45:00 = W3 =2
18:45:00 = T3 = 3019.25
Close Above T3 Alert Triggered

18:46:00 = Both prior cells change values (Now cell 4 and 5) with a new text label and reversal price and the Alerts disappear. A new swing has not started.(Even if it did, surely these previous values should not change?)

Any help in explaining what is happening would be very much appreciated. I have tried many formulas and this always seems to be the case.

I have attached 4 screenshots, spreadsheet before and after values change and charts reflecting the same.

Many Thanks
Date Time Of Last Edit: 2019-09-13 22:58:09
imageSpreadsheet before values change.png / V - Attached On 2019-09-13 22:47:16 UTC - Size: 26.75 KB - 332 views
imageSpreadsheet After Values Change.png / V - Attached On 2019-09-13 22:47:32 UTC - Size: 31.17 KB - 320 views
imageChart Alerts Displayed.png / V - Attached On 2019-09-13 22:47:50 UTC - Size: 14.76 KB - 337 views
[2019-09-13 22:49:10]
Chris_uk - Posts: 89
Last screenshot attached.

Thanks
imageChart Alerts Disappear.png / V - Attached On 2019-09-13 22:48:54 UTC - Size: 13.08 KB - 273 views
[2019-09-14 02:31:40]
Sawtooth - Posts: 3990
The Zigzag study will repaint your alerts when the new leg is building until it is finalized. This is the root of the problem.
Working around this can get complicated.

To reduce some of the repainting, you could use the High instead of the Last in K3:
=AND(W3=2,C3>T3)

If you'd like I can try to reproduce what you see on a 1 minute chart at about 18:45, but I would also need the date and the timezone..
And I would also need the symbol and the relevant ZZ settings.
Date Time Of Last Edit: 2019-09-14 14:10:08
[2019-09-14 21:30:19]
Chris_uk - Posts: 89
Hi Tom,

Many Thanks for taking the time to reply, apologies for the delay in responding.

I will post these settings soon.

I do not understand why the study needs to repaint values from the prior legs for the duration of the 'new leg' development. Surely between a new leg starting and a new leg completing, prior legs values should remain unchanged? In this case the leg[-2] values are reverting back to values from leg[-3]

Is this kind of a behaviour a necessity from a technical standpoint, do you know?
Date Time Of Last Edit: 2019-09-14 21:33:19
[2019-09-14 21:44:10]
Chris_uk - Posts: 89
Hi Tom,

The settings, as requested.

Symbol: S&P 500 September 2019. F.US.EPU19

Time Zone: London(+0GMT/+1BST)

ZZ Settings: Screenshot attached.

Starts at 18:44:00 2019-09-12

Thanks for your suggestion regarding the High. This was just a simple test, my system is more complex and will require many more formulas.

Many Thanks!
Date Time Of Last Edit: 2019-09-14 21:48:19
imageZZ Settings.png / V - Attached On 2019-09-14 21:39:35 UTC - Size: 85.12 KB - 330 views
[2019-09-15 05:40:19]
Sawtooth - Posts: 3990
Referring to your example:

The ZZ line goes above the previous HH only intrabar in the 18:44 bar. When the 18:45 bar opens and builds, the slope of the ZZ line lessens such that its value at the 18:44 bar is no longer above the previous HH.
The ZZ line has a steeper slope in the 18:44 bar than it does in the 18:45 bar because it begins at the HL in the 18:41 bar and lessens its slope as it moves to newer HH bars.
This same thing occurs again in the 18:45/18:46 bars.

The ZZ line's higher intrabar value in the 18:44 bar is not retained, and is unavailable to be used in formulas. The only ZZ line values that are retained are values after the leg finalizes. ZZ line values of the developing leg are not retained.

Since you say your actual formulas are more complex than this test example, I'm not able to offer any formula suggestions to get you the desired result. If you want a more detailed and personalized analysis, you can contact me here:
https://www.sawtoothtrade.com/contact.html
[2019-09-15 14:42:12]
Chris_uk - Posts: 89
Hi Tom,

Thanks for your detailed analysis, after reading it and then watching multiple replays I now have a much greater understanding regarding the repainting. What I am seeing with the previous ZZ values throughout the development of a new leg is much clearer. I could see what was happening before, was just struggling to grasp why it was happening.

I actually get a ZZ line and bar close above the previous HH on the 18.44 bar, it changes for me on the 18:45 bar.

The most important factor for me is that when a formula = True in real-time the trade will get executed. It is just a case of accepting that the alerts on the chart (at a later time) may not necessarily match the trades in the activity log. I will still attempt to find workarounds.

Thanks for your contribution to this forum btw, I have learnt alot from your previous posts. I also use quite a few of your spreadsheet studies, did not know that sawtoothtrade belongs to you.

I may well contact you in the near furture for a consult.

Many Thanks!
Date Time Of Last Edit: 2019-09-15 14:47:58
[2019-09-15 15:14:36]
Sawtooth - Posts: 3990
the alerts on the chart (at a later time) may not necessarily match the trades in the activity log
With 'Signal Only On Bar Close' set to No, you'll get signals intrabar, but only those that are TRUE at the close of bar will show historically.
[2019-09-15 15:41:28]
Chris_uk - Posts: 89
This is an Input I need to start a support thread about. Regardless of whether this option is set to 'Yes' or 'No' I still get intrabar signals. V1986
Date Time Of Last Edit: 2019-09-15 15:44:12
[2019-09-16 05:02:35]
Sawtooth - Posts: 3990
Regardless of whether this option is set to 'Yes' or 'No' I still get intrabar signals.

If 'Signal Only On Bar Close' is set to Yes, intrabar signals will occur but are ignored and don't alert. Only signals that persist until close of bar will alert.

In the 18:44 bar, the signal flashes intrabar, but no alert, then it signals and alerts at close of bar.
Then in the 18:45 bar, the signal that alerted at the close of 18:44 disappears because the ZZ is repainting in the developing leg.

New intrabar signals in the 18:45 bar flash a few times, but no alerts because there were none at close of bar.
More intrabar signals occur without alerts in 18:46, 18:47, and 18:48 bars.
[2019-09-16 14:10:49]
Chris_uk - Posts: 89
Thanks Tom,

I see, I took the name of the Input literally as it states 'only' on bar close.

I was not watching the log at the time of the replay and assumed that alerts were firing off when i saw the buy entry arrows.

Cheers for clearing this up.

To post a message in this thread, you need to log in with your Sierra Chart account:

Login

Login Page - Create Account