In my app,
There is two grid in each x value and both are overlap on eachother..i want to reduce the width of other so that both looks proper.
Please tell me which property is there for this thanks
Code is :
series1.brush = [[IGBrush alloc] initWithColor:[UIColor colorWithRed:90.0/255.0 green:155.0/255.0 blue:55.0/255.0 alpha:1.0]];
series1.xAxis.majorStrokeThickness = 0;
series1.yAxis.majorStrokeThickness = 0;
series1.xAxis.majorStroke = [[IGBrush alloc]initWithColor:[UIColor blackColor]];
series1.yAxis.majorStroke = [[IGBrush alloc]initWithColor:[UIColor blackColor]];
series1.xAxis.labelsVisible = YES;
series1.xAxis.overlap=0.5;
Hi,
My guess is that you're not sharing the same X axis among your two series, which is why the series are getting overlayed. Make sure that when you're creating your series you point them to the same X axis. If you're using chart's addSeriesForType method to add series, simply pass in the same x axis key for each series. If you're creating series and axes separately, set the xAxis property of each series to the same instance of your categoryXAxis.
Basically, there is no need to set gap or overlap on your axis. When 2 series share the same axis, they automatically get grouped together and displayed side by side.
Hi max,
I have checked this and both Xaxis are same.
check this:
IGColumnSeries *colSeries = (IGColumnSeries *) [_chart addSeriesForType:[IGColumnSeries class] usingKey:st2 withDataSource:source firstAxisKey:@"xAxis" secondAxisKey:@"yAxis"];//part 1
IGStackedColumnSeries* series1 =(IGStackedColumnSeries*) [_chart addStackedSeriesForType:[IGStackedColumnSeries class] usingKey:@"stackedcolumnseries" withDataSource:stackedChartDataSourceHelper firstAxisKey:@"xAxis" secondAxisKey:@"yAxis"];//part 2
I dont know what is wrong here so please tell me if you know
Thanks
Here's a quick sample that shows a column and a stack side by side.I've also added a screenshot to the zip file.
Let me know if this is what you wanted to achieve.
Did Max's answer solve your problem? Please let us know.