Construction visualization in HB 1.0

Hi @chris

Please see the two images below. What I want to do is to change the colours of legend parameter for construction. I tried to use legendParCategorized component and it doesn’t work. Looks like I am still misunderstood using this component or maybe there is another way to change the colour of legend parameter. Please give me guidance about this

hi @sunarywend,

With the standard leg_par component it works fine.


With the “LB Legend Parameters Categorized” component, if you want to input N colors, you need to set N-1 domains. As it is written in the _colors input description: list of color objects with a length equal to the number of items in the domain +1. In order to have a situation similar to yours, I created 7 HB faces and I wanted to color them according to their name. So, I came up with this solution to do it. Unfortunately, the “HB Color Face Attributes” requires a “LegendParameter” input, so you would get this error: “1. Solution exception:Expected LegendParameters. Got <class ‘ladybug.legend.LegendParametersCategorized’>.”

So, you if you want to use the “HB Color Face Attributes” you need to use the usual “LB Legend Parameters”, as also @Erikbeeren highlighted:


@chris is there anyway that we can have LegendParametersCategorized accepted by “HB Color Face Attributes”? As it would be helpful to be able to customise the legend of the face attributes.

In my case, specifically, so I can maintain the legend and colours, even when I input different HB objects into the “HB Color Face Attributes”. As I want to be able to visualise only certain zones in the model, without the legend and colour changing each time I do so.