Hey, I'm trying to take an ADR script and make it showing only the daily range (even if I'm on 4H timeframe for example). The problem is that what the script shows is 105% of the current price (SPY is 401.72 and ADR shows 424.62).
Thanks in advance
JavaScript:
input length = 14;
input high = FundamentalType.High;
input low = FundamentalType.Low;
plot ADR = MovingAverage(AverageType.wilders, fundamental(high-low,period = AggregationPeriod.DAY), length);
ADR.SetDefaultColor(GetColor(6));
AddLabel (yes, "ADR:" + round((ADR) , 3), Color.light_green);
AddLabel (yes, "ADR:" + Round((ADR / close) * 100, 3) + "%", Color.light_green);