This is most useful for finding entries and looking for exits intraday, ie: how much hypothetical room is there for a trade to run? looking for entries in yellow and orange zones, exiting in blue once the ADR is reached etc.
Reset variable should be used for the end of day close. For forex on Oanda its 1700. Probably a way to do this programatically, if its obvious let me know and i can update it.
Can be set to clip output above 110% once the daily ADR has been fulfilled - this can be turned on or off.
Experimental mode for finding consolidations, based on the ADR for each day not been fulfilled and contracting. can be good for finding pending range expansion.
Code is pretty ugly, feel free to tweak.
current known issues: Indicator doesnt work for many non forex pairs, due to coding laziness. Indicator does not work on 1 minute timeframe.
Bug fixes - now calculates on small timeframes and non forex pairs correctly.
In true TradingView spirit, the author of this script has published it open-source, so traders can understand and verify it. Cheers to the author! You may use it for free, but reuse of this code in a publication is governed by House Rules. You can favorite it to use it on a chart.
it seems that this areas are a problem:
stophighcheck = nz(stophighcheck,open)
stoplowcheck = nz(stoplowcheck,open)
stoprange = nz(stoprange,open)
if adr_5 > adr_5
daycounter := 0.10