Formulas:
VR[i] = tr[i]/pr[i], where
tr[i] = Max(hl[i], hc[i], lc[i]),
hl[i] = High[i]-Low[i],
hc[i] = Abs(High[i]-Close[i-1]),
lc[i] = Abs(Low[i]-Close[i-1]),
pr[i] = Max(MH, Open[i-Length+1])-Min(ML, Open[i-Length+1]),
MH, ML - maximum and minimum prices at range from (i-Length+1) to (i).
Download: