1Copy the scriptPress Copy script above. It reads the file straight from GitHub.
2Open the Pine EditorOpen a TradingView chart and choose Pine Editor at the bottom of the screen.
3Paste over the templateCreate a new indicator, select all of the template text and paste. Press Save and give it a name.
4Add it to the chartPress Add to chart, then adjust the settings with the gear icon next to its name.
Source Code
The code stays on GitHub. The author has not published this script under an open licence, so ForexR does not show its code. Copy script reads the file straight from GitHub into your clipboard, so you can still try it on your own chart. Ask the author before reusing the code anywhere else.
Overview
Drawn in a separate pane, it offers options to wait for bar confirmation before updating values and can invert the ATR scale. The script also draws a horizontal level line at the current ATR value across the chart. User settings control the ATR calculation period, smoothing type, scale inversion, and visual display options for level lines and extreme markers.
Multiple smoothing methods including RMA, SMA, EMA, and WMA
Bar confirmation setting to delay ATR updating until candle close
Scale inversion feature to multiply ATR values by negative one
Horizontal line display tracking current ATR level
Visual customization for 3-day and 7-day extreme markers
The inputs you can change from the gear icon on the chart. Defaults are the author's.
Setting
Type
Default
Variable
Length
int
14
length
Smoothing
string
RMA
smoothing
Wait for period end before updating
bool
true
waitClose
Flip scale (invert ATR)
bool
false
flipScale
Show current value horizontal line
bool
true
showHLine
Horizontal line color
color
color.new(#B71C1C, 0)
hLineColor
Horizontal line style
string
Solid
hLineStyle
Horizontal line width
int
1
hLineWidth
Show 3-day low marker
bool
true
show3DayLow
3-day low color
color
color.new(#FF9800, 0)
low3DayColor
3-day low style
string
Circle
low3DayStyle
Show 3-day high marker
bool
true
show3DayHigh
Show all 20 settings
Setting
Type
Default
Variable
3-day high color
color
color.new(#4CAF50, 0)
high3DayColor
3-day high style
string
Circle
high3DayStyle
Show 7-day low marker
bool
true
show7DayLow
7-day low color
color
color.new(#FF5722, 0)
low7DayColor
7-day low style
string
Circle
low7DayStyle
Show 7-day high marker
bool
true
show7DayHigh
7-day high color
color
color.new(#2196F3, 0)
high7DayColor
7-day high style
string
Circle
high7DayStyle
Third-party code. ForexR did not write, test or endorse this script, and the summary above was generated automatically from its code and README. Indicators describe the past, and a strategy's backtest can look better than live trading, especially when a script repaints. Check it in the Strategy Tester and on a demo account before you rely on it.
This indicator calculates the distribution of close-to-close percentage changes using rate of change on closing prices. It bins percentage changes into intervals of 0.25 percent increments from negative to positive values and plots a normalized cumulative hist
This indicator plots a Supertrend-based trend-following setup in a separate pane and skips conditions it treats as a sideways market. A volatility range is built from an ATR value, with RMA, SMA, EMA, or WMA smoothing, or from a fixed point distance. Optional
This indicator plots candle range and open-to-close movement as percentages in a separate pane. Range is the high-low difference divided by the low, and change is the close-open difference divided by the open. Both series draw as columns. Teal columns show ran
The Mojito v3 Strategy indicator evaluates volatility term structure by calculating the ratio between front-month and second-month VIX futures contracts. It smooths this ratio using a configurable median filter and compares the result against user-defined uppe
Calculates dynamic modeling values by applying a mathematical logistic differential equation to price change over a specified lookback length. It measures price momentum relative to the recent high-low price range. The script plots positive and negative logist
MACD-V is a volatility-normalized momentum indicator based on research by Alex Spiroglou. It calculates the standard MACD histogram and normalizes it by dividing by the Average True Range (ATR). Plotted in a separate pane as a colored histogram, it includes us