Stacked Column chart with Line Series


#1

Hi, 

I was looking into the shinobichart API and could work on the basic column chart and line series. What I actually desire as an end result is a stached column chart combined with the line graph. Please find attached an image of the end result. Can you please help me out in this and let me know if that is possible by using the Shinoby Library and if its possible how to do it…

Stacked Bar Line chart


#2

Hi kapsym,

That is definitely something we can do in Shinobi!

For the Line + Columns, the “MultipleAxes” code sample might help you, although you will only need one axis, so can ignore any of the “volumeAxis” code.

For the stacked columns, if you set the “columnSeries.stackIndex = @0” in sChart:seriesAtIndex:", the columns will stack up on top of eachother.


#3

Is something like the above chart currently supported in v1.2 on Android?


#4

Hi ptashek,

We don’t have stacked series or multiple axes in V1.2, but both features will be in V1.3, provisionally due for release at the end of the month.

Best regards,

Robin Sillem


#5

HiI did this chart by drawing bar and line graph and putting them in the same stack index. While I was able to achieve the result, one issue that I am facing is that the points on the x axis are not coming sequentially and get plotted in random order. so if I give it days of the month like 1 2 3 4 it picks up random values and x axis might have a plot as 3 1 4 2. Can you please let me know how i ensure the graph is plotted in the same order as provided in the json or the array.


#6

Hi kapsym,

For stacked series, the chart requires that the data points in each series are ordered such that their x values (for column series) are in ascending order. If this is not the case, the algorithm being used for stacking will not work as expected. This is something we mention in our API docs, but it might be the case that we need to make this clearer. In any case, if you order your data points before you provide them to the chart in your datasource, do you find that the chart now renders correctly?

Best regards,

Dan