Profile Picture


Posted By ywlee 4 Years Ago
Posted Tuesday May 27 2014
Hi I'm testing based on 10 min bars and the values returned are off. It's the ATR programmed to calculate bard on daily bars?
Posted Wednesday May 28 2014
No, the ATR will be based on the frequency of the bars. The formula used is from Technical Analysis from A to Z, and the way it calculates the average is a bit weird. Until the number of bars specified by the periods, the value will be a simple average of the true range values (with a special case for the first bar). Afterwards, the average is calculated like an EMA, but the value for the periods is used differently. Here's the formula:

atr = (1.0 / (double)periods * (tr - previousATR)) + previousATR;


Similar Topics

Reading This Topic

2005-2018 © RightEdge Systems