Support Board
Date/Time: Wed, 26 Feb 2025 09:46:29 +0000
[Programming Help] - Alert Accessing Multiple Charts and Subgraphs
View Count: 614
[2021-05-17 21:37:46] |
Metzenovich - Posts: 10 |
Say I have a chartbook with 3 charts: #1 (15 min), #2 (5 min), #3 (1 min). If I want an alert on chart #3 (1 min) that compares values from all 3 charts and various subgraphs, how can I do this? What I want to accomplish is basically (very simple example) to alert me when #3.ID5.SG2[-1] < #3.ID5.SG2[-2], and #2.ID5.SG2[-1] < #2.ID5.SG2[-2], and #1.ID5.SG2[-1] < #1.ID5.SG2[-2], etc. (I know #3.ID5.SG2[-1] isn't valid syntax, I'm just using it for illustration purposes). What is the best way to do this? I tried the Study/Price Overlay but the subgraph I was trying to overlay references other subgraphs and wasn't coming over (it was empty, a flat line). I think it was because 3 or 4 subgraphs are used to calculate the value I want to import. Is a custom study a viable / better way to do that? If so can someone point me towards the documentation or syntax for referencing multiple charts / subgraphs from a custom study? Thanks! Date Time Of Last Edit: 2021-05-17 21:38:21
|
[2021-05-17 22:32:20] |
Sawtooth - Posts: 4175 |
You can't reference another chart in an Alert formula, so you'll need to use the Study/Price Overlay study on chart #3. Before you overlay from charts #1 and #2, combine the calculated values in one study on charts #1 and #2. You can use the Spreadsheet Formula study for this. (Despite its name, this is not a spreadsheet study.) Then overlay that study on chart #3. When all studies are on chart #3, you can create the alert formula. |
[2021-05-18 04:08:19] |
Metzenovich - Posts: 10 |
Thank you for the help. I figured out that the "Value Format" was set to 0.001, but the value was like 0.0000123485, so it was showing up as 0 in the Alert Manager. I also figured out I needed to set "Match Source Bars to Destination Bars" to No. Now it works as expected using the Study/Price Overlay study. Thanks! |
To post a message in this thread, you need to log in with your Sierra Chart account: