Login Page - Create Account

Support Board


Date/Time: Sun, 11 May 2025 16:43:07 +0000



Post From: Alert bar syntax for % difference

[2019-06-06 15:48:16]
Sawtooth - Posts: 4214
For a ratio of High minus Close to the bar's range:
=(H-C)/(H-L)
For a ratio of Close minus Low to the bar's range:
=(C-L)/(H-L)

To apply these formulas to a study's values, the study must output OHLC values in separate subgraphs, e.g. the Daily OHLC study as ID1:
=(ID1.SG2-ID1.SG4)/(ID1.SG2-ID1.SG3)
=(ID1.SG4-ID1.SG3)/(ID1.SG2-ID1.SG3)

To get an alert greater than 60%:
=(H-C)/(H-L)>0.6
=(C-L)/(H-L)>0.6