Directional Volatility indicator. The indicator displays two volatility lines – bullish and bearish ones.
It has two configurable parameters:
- Period – calculation period
- Deviation – deviation
It is calculated with the standard deviation from a mean of the last X Period, made of distance between the last Close with the High/Low depending of the direction (short or long curves).
Converted from a mq5 indicator by a request in the English forum.
//PRC_DirectionalVolatility | indicator
//Nicolas @ www.prorealcode.com
//Sharing ProRealTime knowledge
// --- settings
// --- end of settings
ShortS = Close - Low
ShortMA = average[Period](ShortS)
ShortDev = Std[Period](ShortMA)
LongS = High - Close
LongMA = average[Period](LongS)
LongDev = Std[Period](LongMA)
Short = ShortMA + Deviation * ShortDev
Long = LongMA + Deviation * LongDev
return Short coloured(255,0,0), Long coloured(0,255,0)
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 :