How to place the second YAxis below the primary XAxis?


#1

I use shinobicontrols-android-charts-premium-java-1.9.1-0.aar to develop the stock price and the volume time chart, a XAxis represent the time and two YAxis represent the price and the volume, the price YAxis above the time XAxis, the volume YAxis in time XAxis Below, shinobicharts Android premium release support multiple axis,but the chart will stack the axes with the first axis innermost and the last axis outermost. In the shinobicharts iOS release,The SChartAxis has the secondaryAxisOffset property that can places the two YAxis above and below the XAxis. Will shinobicharts Android premium release have a property like secondaryAxisOffset other implementations?

shincbichars for android:

Other chart can place the second YAxis below the primary XAxis,like this:


#2

Hello,

Thank you for getting in touch.

Currently, shinobicharts for Android does not offer an equivalent API method to our iOS charts’ secondaryAxisOffset method. We do base our future development on customer demand, so I will be sure to register your interest in it.

In the meantime, you should be able to achieve a similar look and feel using a different approach.

One option is to use two charts, one above the other, hiding the x axis of the upper price chart. Both x axes would typically contain the same values and range.

Another option is to use one chart and 2 y axes, each y axis in the reverse position. As you have mentioned, the secondary y axis is stacked on the first y axis. In the case of a y axis in the reverse position, the secondary y axis would be stacked to the right of the primary y axis.

If you apply a negative tick gap to the secondary y axis you could potentially align the tick labels of both primary and secondary y axes. This can be done using the following method:

https://www.shinobicontrols.com/docs/ShinobiControls/ShinobiChartsAndroid/1.9.1/Standard/Normal/apidocs/reference/com/shinobicontrols/charts/TickStyle.html#setTickGap(float)

To prevent the chart leaving space for secondary y axis, you may wish to set the width of the secondary y axis to a smaller value using the following method:

https://www.shinobicontrols.com/docs/ShinobiControls/ShinobiChartsAndroid/1.9.1/Standard/Normal/apidocs/reference/com/shinobicontrols/charts/Axis.html#setWidth(java.lang.Float)

I hope that this helps, please let us know if you have any further questions.