public IndicatorPlotting(string label, ChartTypeOption chartType, ChartRangeOption chartRange, bool showByDefault = true) { this.chartType = chartType; this.chartRange = chartRange; this.label = label; this.showByDefault = showByDefault; }
public IndicatorChartingInfo(int indicatorIndex, string identityCode, string seriesLabel, ChartRangeOption chartRange, ChartTypeOption chartType, bool multiValue = false) { this.indicatorIndex = indicatorIndex; this.identityCode = identityCode; this.seriesLabel = seriesLabel; this.chartRange = chartRange; this.chartType = chartType; this.multiValue = multiValue; }
public void ChangeChartType(ChartTypeOption chartType) { switch (chartType) { case ChartTypeOption.Candlestick: this.Series.ChartType = SeriesChartType.Candlestick; break; case ChartTypeOption.Line: this.Series.ChartType = SeriesChartType.Line; break; case ChartTypeOption.PriceBar: this.Series.ChartType = SeriesChartType.Stock; break; } }
void IPipChart.PlotIndicator(string indicatorName, ChartIndicatorItem[] indicatorItems, ChartTypeOption chartType) { pipChart.AddIndicatorSeries(indicatorName, indicatorItems, chartType, pipChartId); }
void IPriceActionChart.ChangeChartType(ChartTypeOption chartType) { priceActionChart.ChangeChartType(chartType); }
void IOscillatorChart.PlotIndicator(string indicatorName, ChartIndicatorItem[] indicatorItems, ChartTypeOption chartType) { oscillatorChart.AddIndicatorSeries(indicatorName, indicatorItems, chartType, oscillatorChartId); }
public void AddIndicatorSeries(string indicatorName, ChartIndicatorItem[] indicator, ChartTypeOption chartType, string chartArea) { if (this.SeriesCollection.FindByName(indicatorName) != null) { this.SeriesCollection.Remove(this.SeriesCollection.FindByName(indicatorName)); } Series indicatorSeries = new Series(indicatorName); switch (chartType) { case ChartTypeOption.Line: indicatorSeries.ChartType = SeriesChartType.Line; break; case ChartTypeOption.Histogram: indicatorSeries.ChartType = SeriesChartType.Column; break; case ChartTypeOption.Point: indicatorSeries.ChartType = SeriesChartType.Point; break; } //indicatorSeries.IsVisibleInLegend = false; for (int indicatorIndex = indicator.Length - 1; indicatorIndex >= 0; indicatorIndex--) { ChartIndicatorItem indicatorItem = indicator[indicatorIndex]; indicatorSeries.Points.AddY(indicatorItem.Value); } indicatorSeries.ChartArea = chartArea; this.SeriesCollection.Add(indicatorSeries); }