Moving Standard Deviation

The calculation of standard deviation will vary depending on the method of implementation. The statistician has discretion to specify the pattern of distribution and "degrees of freedom" for the underlying data.

Study Type: Stand-alone


US futures and futures options calculations have typically used standard deviation calculations based on a normal data distribution and zero degrees of freedom. This gives tight correlation between implied and historical volatility, and will produce narrower support and resistance channels for futures studies which use standard deviation and variance in their formulas.


Barchart Trader uses the sample standard deviation formula with zero degrees of freedom. Variations on this formula will use (number of data points -1) in step 4.below.

  1. Calculate the average value for the underlying data points.
  2. Calculate the difference between the average value and each data point.
  3. Square the differences from step 2 above and add them up.
  4. Divide the total from step 3 by the number of data points.
  5. Take the square root of the result from step 4.


  • Period (20) - the number of bars, or period, used to calculate the study