SQRT ( 1/(N-1) SUM (POWER(X(i) - SMA(i))))
Actual calculation in NinjaTrader is SQRT ( 1/N SUM (POWER(X(i) - SMA(i))))
With this calculation there are small differences to other charting applications, Excel, Calculators. It would be easier and more comparable to transfer a system to NinjaTrader.
See also: http://www.ninjatrader-support.com/v...ead.php?t=7447
implementation is easy:
in StdDev.cs
Value.Set(Math.Sqrt(sum / Math.Min(CurrentBar + 1, Period)));
has to be changed to
Value.Set(Math.Sqrt(sum / Math.Min(CurrentBar + 1, Period-1)));
(maybe an extra check vor div by zero)
Any support for this suggestion?
Comment