Difficulty Combining Results from Excel with Rendering using Human Toolbox

Hi there,

I have inherited a script that I have made some slight modifications to. The script takes some analysis results from excel and plots it in Rhino using this gh script. The excel file contains information about either the damage state of a wall panel (a number 1-5) or a pressure value associated with that wall panel (in kPa). These values are mapped to a color gradient and then plotted in Rhino in a layer corresponding to either the damage state or the pressure. The pressure values are separated into equal spaced groups so as to try and limit the number of layers that get plotted. My question has two parts: 1) When I bake the results instead of 685 surfaces (the number of wall panels modeled) I end up with many thousands of surfaces. Why is this occuring? I thought I am feeding in just the list of each panel and it’s damage or pressure into the layer generation part of the script? 2) When I try and plot the pressure vales (grouped into say 20 equal intervals), I still end up with a unique layer to every single pressure (685 instead of the 20 that should be there). Again when this is baked, the same problem occurs.

Any help or guidance would be greatly appreciated! I’ve attached the sample geometry, and the script itself as well as a hyperlink to the excel info.
Excel: Excel Workbook
Test File.GH (49.0 KB) Damage Calc Sample File.3dm (8.7 MB)

Duplicate post - answered here: