Search code examples
iosiphonecore-plotscatter-plotxcode7.2

how to move cptscatterplot line little forward


I have implemented cptscatterplot lines.In my app, i have bars under labels and based on yvalues cptscatterplot line will be drawn.

If value is empty then i am breaking the line and continuing again if value is valid, but the line ends with starting point of the bar that bit confusing whether it is valid or not.

can some one help me that can we move line to middle of the bars, i mean starting/ending the line in the middle of the bar.

Thanks in advance. Please help me regarding this struggling alot.


Solution

  • You can move either the bars or the scatter plot line. To move the bars, use the barOffset property or add an offset to the bar locations. To move the scatter plot, add an offset to the x-values of the plot.