public static double Value(TimeSeries input, int index, int length, double k, BarData option) { if (index < length - 1 + input.FirstIndex) { return(double.NaN); } double num1 = BBL.Value(input, index, length, k, option); double num2 = BBU.Value(input, index, length, k, option); return((input[index, option] - num1) / (num2 - num1)); }
public static double Value(DoubleSeries input, int index, int length, double k) { return(BBU.Value((TimeSeries)input, index, length, k, BarData.Close)); }
protected override void Calculate(int index) { double Data = BBU.Value(this.fInput, index, this.fLength, this.fK, this.fOption); this.Add(this.fInput.GetDateTime(index), Data); }