Scatter xaxispos center leads to abnormal y scales

Share RGraph:  

« Back to message list

Enter your email address to get email updates on this topic. You can stop receiving updates by clicking the link in the update email messages.

Posted by malaise on 18th November 2015
On a Scatter I have set
ymin: -15,
ymax: 45,
xscale: true,
ylabelsCount: 12,
numyticks : 12,
And output is OK.

Now I add: xaxispos: 'center',
and the Y scale values become garbage around 0.

I expect -10, -5, 0 with the axis, 5, 10 ...
I get -10, -5, -0, -5, -10, nothing with the axis, -10, -5, 0, 5, 10...

Posted by Richard on 18th November 2015
Hi there,

Setting the ymin to a negative value when the Y axis is in the center probably won't do what you want.

There are examples of offset Y axes in the /demos/ folder (called quarter-axis charts) - but they're more involved than simply setting properties (I've even tried this with the Scatter chart).

Posted by malaise on 19th November 2015
Ok I will do it this way, thank you.

Maybe a good improvement of the Scatter would be to support xaxispos: 'zero', or even xaxispos: number?

Add a reply

« Back to message list