Reputation: 594
I have worked with Bar graphs with Core Plot, but i couldn't find a way to get a horizontal bar chart containing bars with multiple values. Is there a way to do it in Core Plot?
Here is an image of what i want to do.
Upvotes: 3
Views: 1552
Reputation: 12528
I know it is a really old post. But I have recently created a library which is creating horizontal bars from given values. It's written in Swift and maybe someone can use this in future projects.
https://github.com/prine/ROStorageBar
Upvotes: 1
Reputation: 27381
You can do this with stacked bar plots. Make one bar plot for each section and set barBasesVary
to YES
for each one. This causes the plot to query the datasource for an additional field called CPTBarPlotFieldBarBase
for each bar. Use this to set the lower edge of the bar.
The "Vertical Bar Chart" in the Plot Gallery example app demonstrates this technique.
Upvotes: 1