SwiftChart icon indicating copy to clipboard operation
SwiftChart copied to clipboard

Centered Data Points

Open tomasbek opened this issue 8 years ago • 2 comments

Hello everybody,

I'd be very happy to know if there is a way to 'center' the data points in regards to the x-scale. In order to make my request easier to understand please refer to the picture I attached (please ignore the colors).

5c303ac6-9adc-11e5-9006-3275a16b7ec8

I have tried to overcome this issue with adding 0.5 to my x values (for example, adding 0.5 to 6), which indeed made the data points centered. This, however, broke the accuracy of the didTouchChart function.

Thank you in advance!

tomasbek avatar Nov 14 '17 20:11 tomasbek

did you find a good solution for this?

haemi avatar Dec 15 '17 06:12 haemi

Have you tried using the xLabels property as shown in this example? Together with xLabelFormatter you should move the labels and the vertical line.

https://github.com/gpbl/SwiftChart#partially-filled-series

gpbl avatar Jan 06 '18 15:01 gpbl