Limiting Axis range values


#1

I’m using Shinobi iOS control for drawing line charts in my app. I’m currently rendering a serious of 0s value. The resulting graph is like that:

enter image description here

Now, the problem is that the quantity I’m representing is a currency so it cannot be negative. How can I limit the range to start from 0 in this specific case?


#2

Initialise your chart with a default range of 0 to MAX like so (where MAX is what you want your upper limit to be):

chart.yAxis = [[SChartNumberAxis alloc] initWithRange:[[SChartRange alloc] initWithMinimum:@0 andMaximum:MAX]];

Thanks,
Jan