This script has been originally edited by HPotter and Sylvain Vervoort
Some aspects have been modified and added such as:
- ATR line color
Alerts are added
Fixed the inputs now can be adjusted with decimals without the keyboard.
Securitys are added to the source
Color bar is added
Average True Range (ATR) Trailing Stops
ATR Trailing Stops are primarily used to protect capital and lock in profits on individual trades but they can also be used, in conjunction with a trend filter, to signal entries.
Average True Range ("ATR") was introduced by J. Welles Wilder in his 1978 book New Concepts In Technical Trading Systems. ATR is a measure of volatility for a stock or index and is explained in detail at Average True Range. Wilder experimented with trend-following Volatility Stops using average true range. The system was subsequently modified to what is commonly known as ATR Trailing Stops.
ATR Trailing Stop Signals
Signals are used for exits:
Exit your long position (sell) when price crosses below the ATR trailing stop line.
Exit your short position (buy) when price crosses above the ATR trailing stop line.
While not conventional, they can also be used to signal entries — in conjunction with a trend filter.
Lenght 16 - Multiplier x 2
A second ATR with custom resolution is added
Remember to give thanks for the original essential formula to =
After seeing that there is a certain margin of error when using the second frame .. "I don't know why" I have added individual adjustments to be able to compensate for the error, everything else remains the same
Nello spirito di condivisione promosso da TradingView, l'autore (al quale vanno i nostri ringraziamenti) ha deciso di pubblicare questo script in modalità open-source, così che chiunque possa comprenderlo e testarlo. Puoi utilizzarlo gratuitamente, ma il riutilizzo del codice è subordinato al rispetto del Regolamento. Per aggiungerlo al grafico, mettilo tra i preferiti.