Grasshopper

algorithmic modeling for Rhino

data labels overlap with each other for the stackValues option in bar chart

The data labels are shown for each bar when are not "stacked up":

But the data labels overlap on the same location when "stackValues" is selected on the bar chart component:

So, is there a way to allow the data labels to show beside each bar even when they're stacked up?

Thanks!

Views: 765

Replies are closed for this discussion.

Replies to This Discussion

Grasshope,

Thanks for bringing this to my attention.  I had imagined that most people would use the dataLabePt of a stacked chart like this to label the sum of all energy use or energy load but I could be wrong.  I can put in a tree branch of points for the different stacked bars if you think it would help.  In the meantime, you can just use the native GH "Move" component to create two more copies of the points to align with the input data.

-Chris

Thank you, Chris!

It will be great if the value label is positioned besides the color "patch" with which it associate.

Meanwhile, Antonello's suggestion below is also a nice workaround.

- Ji

Hi Grasshope and Chris,

This is a possible way to deal the overlap of the numbers.

You could use "_labelPtsOffset_" input of the latest version of the bar chart component and you should use a couple of native components of GH to manage the lists.

Best

Antonello

Thanks, Antonello!

However, it seems the latest bar chart component is not able to read the output variable directly from the latest read ep results component, what I got is some kind of line chart:

Other than that, you suggestion is working nicely:

However, the non-stackValue option is still not working in my workflow, hope you and Chris can kindly advise (see the demo file attached):

Thank you both!

-Ji

Attachments:

Antonello,

I like your method.  It's much more grasshoppery.  Given these solutions, I might make the implementation of more points on the chart a lower priority for the time being.

Ji,

1) The monthly bar chart displays hourly results as lines.  Request monthly outputs from the simulation to get a bar chart.

2) Read the orange balloon on the bar chart component.  It is telling you that all of the values of one of your lists are 0 and that you should use legendpar to correctly scale the Y-Axis. More info is here:

https://github.com/mostaphaRoudsari/ladybug/issues/276

-Chris

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

© 2025   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service