Color Range

Dear All,

Is it possible to create a color range for these cuboids…means each cuboid has a specific color which is derived from its height?

Thanks.

ColorRange

ColorRange

Here is the .dyn file…

Hello Chander Gupta,

You can not color Geometries which are visible in Dynamo background preview, you need to transfer those Solids to Revit (in Project document only) and then you can override its color using Color Range.

See attached image.

Let me know if you are not clear about anything.

Thanks,

Ritesh
ColorInDynamo

ColorRange

 

 

 

 

Hi Ritesh,

It was quite easy, after you showed me how to do it :slight_smile:

I still dont understand the function of ‘List.Map’. could you explain it a bit pls?

Thanks so much !

Hi Chander,

the map node takes a function (f(x)) - which in the case of Ritesh’s graph was ImportInstanceByGeo() - and it does that function to each item in the list which is also supplied to the map node.

Then it aggregates the result, so the result is a new list of whatever the import instance function returns.

Hi Michael,

Thanks so much for your input !

Pls compare Ritesh’s snapshot with mine. I didn’t use the Map.List function & the output is still the same.

Thats the reason, i questioned the meaning of Map.List node…

Perhaps Map.List is meant for specific functions/operations which cannot be performed otherwise…??

Regards.

Hello Chander Gupta,

In my graph I was getting Single Solid in Revit after Import, and that is the reason I used List.Map. Let me try your graph and will come back to you.

List.Map is a Node which you can use when you have List of List elements (or List of elements) and you want to Perform certain Operation on each element, then you can use List.Map operation.

see simple example below which explain where to use List.Map and where to use direct function.

Thanks,

Ritesh

List.mapExample

Thats very Interesting.

Thanks Ritesh !