Hiding Invalid Data in the Financial Price Series
Send Feedback

Glossary Item Box

Topic Overview


This topic provides an introductory overview of hiding invalid data in the financial price series on the IGChartView™ control.

In this topic

This topic contains the following sections:


Hiding invalid data summary

OHLC points have always been allowed to show in the chart regardless of the underlying values. However, a financial chart should not show points where the low value is greater than high value. To hide invalid values set the OHLC data source helper’s property restrictLowsGreaterThanHighs to YES.

Note: To take advantage of this feature, a data source helper must be used.

In Objective-C:

_chart = [[IGChartView alloc]initWithFrame:self.view.frame];
_ohlcHelper = [[IGOHLCSeriesDataSourceHelper alloc]initWithData:_data openPath:@"open" highPath:@"high" lowPath:@"low" andClosePath:@"close"];
_ohlcHelper.restrictLowsGreaterThanHighs = YES;
[_chart addSeriesForType:[IGFinancialPriceSeries class] usingKey:@"series" withDataSource:_ohlcHelper firstAxisKey:@"x" secondAxisKey:@"y"];
IGFinancialPriceSeries *s = [_chart findSeriesByKey:@"series"];
s.displayType = IGPriceDisplayTypeOHLC;
[self.view addSubview:_chart];

In C#:

_chart = new IGChartView (this.View.Bounds);

_ohlcHelper = new IGOHLCSeriesDataSourceHelper (_data.ToArray (), "Open", "High", "Low", "Close");

_ohlcHelper.RestrictLowsGreaterThanHighs = true;

_chart.AddSeries (new ObjCRuntime.Class ("IGFinancialPriceSeries"), "series", _ohlcHelper, "x", "y");

IGFinancialPriceSeries s = _chart.FindSeriesByKey ("series");

s.DisplayType = IGPriceDisplayType.IGPriceDisplayTypeOHLC;

this.View.AddSubview (_chart);

Related Content


The following topic provides additional information related to this topic.



The topics in this group cover enabling, configuring, and using the IGChartView control’s supported features.