Interesting!
I have been using ATR for takeprofit and stoploss in scalping bots for years. It works really well! something like this
stoploss=atratrslfactor;
takeprofit=atratrtpfactor;
Its a simple concept. Your take profit and stoploss are more dynamic and based on market conditions.
Although if you were manually trading you could just draw a pair of straight lines to determine the market range… You can use it for a particular day, or particular session, etc…
Also use atr for lot size (risk) . Usually there is less risk in a ranging market. (depending on system).
Anyway, it is a very useful indicator.