Another new channel indicator made of price differences (high or low) from a moving average (40 periods EMA) and ponderate by the recent average true range (14 periods).
The result of this calculation is then smoothed by another Exponential Moving Average of 3 periods. This is the “center” of the band. The upper and lower bands are calculated with the standard deviation 200 periods from this center value (smoothed with another 40 EMA beforehand).
The indicator act as an oscillator with dynamic overbought and oversold areas, that could be used as potential reversal zones or breakout ones to trade in the same direction.
This code come from a Kirk Northington’s book.
Coded by a request on the Italian forum, translated from a Metastock formula.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
//PRC_TTI ATR Extreme | indicator //19.04.2017 //Nicolas @ www.prorealcode.com //Sharing ProRealTime knowledge atr=(averagetruerange[14]/Close) if close<exponentialaverage[40] then x = (((Low - average[40,1](low))/Close)*100)*(ATR*100) else x = (((High - average[40,1](high))/Close)*100)*(ATR*100) endif avg = average[40,1](x) dev = std[200](x) upperband = avg+dev center = average[3](x) lowerband = avg-dev return upperband coloured(0,139,69) style(dottedline,1) as "upper band", center style(line,2) as "center line", lowerband coloured(220,20,60) style(dottedline,1) as "lower band" |
Share this
No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.
ProRealTime ITF files and other attachments :PRC is also on YouTube, subscribe to our channel for exclusive content and tutorials
Sei grande Nicolas 🙂
Dear Nicolas,
Great work, thank you very much!I would love to use the indicator in ProScreener. However, regardless of the stock list I choose, PRT does not come up with any values (even though the condition should be met).This is the code of the ProScreener (created by using the ProScreener assistant) – really simple in order to exclude any other potential sources of error:
ignored, indicator1, ignored = CALL “PRC_TTI ATR Extreme”(close)c1 = (indicator1 > indicator1[1])SCREENER[c1]
Do you (or anyone else) have any idea why ProScreener does not seem to filter out any stock?Thank you very much in advance!!
btw: The above-posted ProScreener is supposed to show stocks for which the center line has increased vs. last period