public void Update(TradeBar currentBar) { IBaseData dataPoint; if (typeof(Z) == typeof(TradeBar)) { dataPoint = currentBar; } else { dataPoint = new IndicatorDataPoint(currentBar.EndTime, currentBar.Close); } Indicator.Update(dataPoint); decimal value = Indicator.Current.Value; if (_indicatorIsPercent) { value *= 100; } IndicatorSeries.AddPoint(Indicator.Current.Time, value); if (Indicator.IsReady) { STD.Update(Indicator.Current.Time, value); IndicatorSeriesSTD.AddPoint(STD.Current.Time, STD.Current.Value); } }
public void Update(DateTime time, decimal iv) { var point = new IndicatorDataPoint(); point.Time = time; point.Value = iv * 100; //IV given in percent terms STD.Update(point); }
public void Update(DateTime time, decimal iv_ratio) { IVSkewSeries.AddPoint(time, iv_ratio * 100); //IV given in percent terms var point = new IndicatorDataPoint(); point.Time = time; point.Value = Math.Abs(iv_ratio * 100); //IV given in percent terms STD.Update(point); }
public void Update(DateTime time, decimal max_pain_strike, decimal max_pain_distance) { MaxPainSeries.AddPoint(time, max_pain_strike); var point = new IndicatorDataPoint(); point.Time = time; point.Value = Math.Abs(max_pain_distance); STD.Update(point); MaxPainRelSTDSeries.AddPoint(time, STD.Current.Value); }
public void Update(DateTime time, decimal frontiv, decimal backiv) { FrontIVSeries.AddPoint(time, frontiv); BackIVSeries.AddPoint(time, backiv); var point = new IndicatorDataPoint(); point.Time = time; point.Value = (backiv * 100) - (frontiv * 100); //IV given in percent terms STD.Update(point); STDSeries.AddPoint(time, STD.Current.Value); }