Hi,
There is the ATR indicator but it just take CLOSE as the parameter. I wonder if there is ATR which take HIGH, LOW and CLOSE as input?
The built-in Atr DOES allow to select the data source parameter (see pic).
In any case, this a custom version you can tailor to your needs by selecting the data source with the indicator properties (it’s the same as PRT’s):
src = customclose
p = 14
MyTR = max(Range,max(abs(high - src[1]),abs(low - src[1])))
IF BarIndex < p THEN
MyATR = MyTR
ELSE
MyATR = ((MyATR[1] * (p - 1)) + MyTR) / p
ENDIF
RETURN MyATR