stdev

stdev(series, period)
Parameters
  • series (series) – Input series

  • period (integer) – Input period

Returns

series

Returns the standart deviation (\(\sigma\)) of the last period bars in the series.

\[\begin{split}\overline{x} &= \frac{\sum_{i=0}^{period - 1}x_i}{period}\\ \sigma &= \sqrt{\frac{\sum_{i=0}^{period - 1}(x_i - \overline{x})^2}{period - 1}}\end{split}\]