You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi there,
is there a way how I can configure two datasets, one having dataSet.axisDependency = .left and the other dataSet.axisDependency = .right to have the zero line at the same spot?
As you can see in the screenshot, they have a very different scaling. The right axis has its zero line at the very bottom (I am not displaying it), the left one in the middle. The X axis values here are very different, but it should only be a matter of scaling in my opinion. But I could not find a way to do this.
Ideally like this, where the axis are scaled in a differently, but have the same zero line.
The text was updated successfully, but these errors were encountered:
well, if you want to have diferent range and keep the 0 line at the same position, it's kind of tricky;
the simpliest way is to use same axis range for both left and right axis, but if your line and bar data range vary a lot, one of them may seems very small.
if you really want this, you have to do this. You need to make sure you carefully calculated the axis range and interval, to make sure your 0 draw at the same y position.
That means when your left axis know where is the 0 position, it have to tell right axis where is the 0 position, and then you start calculating the axis interval around 0.
you need to carefully look at how it calculate the matrix and computeAxisValues().
same question here: #2989 but yours have negative values, so things are more comlex.
Hi there,
is there a way how I can configure two datasets, one having
dataSet.axisDependency = .left
and the otherdataSet.axisDependency = .right
to have the zero line at the same spot?As you can see in the screenshot, they have a very different scaling. The right axis has its zero line at the very bottom (I am not displaying it), the left one in the middle. The X axis values here are very different, but it should only be a matter of scaling in my opinion. But I could not find a way to do this.
Ideally like this, where the axis are scaled in a differently, but have the same zero line.
The text was updated successfully, but these errors were encountered: