Support Board
Date/Time: Thu, 28 Nov 2024 00:52:16 +0000
Swing High and Low
View Count: 1090
[2014-10-24 22:57:32] |
jivetrader - Posts: 410 |
trying to write an alert using this study. Since i cannot just poll the previous bar and find a match, How might i identify the bar with the previous occurrence of the SG1 or SG2 ?
|
[2014-10-24 23:57:01] |
Sawtooth - Posts: 4120 |
Try one of these: =SG1[-4]>0 =SG2[-4]>0 or OR(SG1[-4]>0,SG2[-4]>0) where the [-4] value is one bar less than the Length setting of 5. |
[2014-10-25 00:23:19] |
jivetrader - Posts: 410 |
thanks. so I would probably need a spreadsheet study to find the OHLC of whatever bar it finds is the previous swing high. ?
|
[2014-10-25 00:43:34] |
Sawtooth - Posts: 4120 |
Yes, because Simple Alerts are only T/F. Use a formula like this in a Formula Column on the spreadsheet, e.g. in cell M3: =IF(AA3>0,C3,M4) This will grab the High when there is a new swing high in column AA, and repeat it until the next swing high. |
[2014-10-25 01:21:13] |
jivetrader - Posts: 410 |
great tip. saved me a lot of index & match. cheers mate
|
To post a message in this thread, you need to log in with your Sierra Chart account: