Hello EveryBody,
Hope you are all Fine.
I am making a code in dynamo where I want groups of families (for example 10 or 15, varying the amount) and join these groups of families with polycurves using points created with solid.centroid, so that the points closest to each other are joined. For this I relied on a previous forum.https://forum.dynamobim.com/t/closest-point-for-given-point-sorting-loop/12600/11?u=nfelipe.cardona.
So far I have the code like this:
And when running it for groups of 18 elements, you get the following:
The problem is that it is not grouping the closest points, as I need it. For example, taking as a reference the first group that is created, how can it be done that instead of joining the points like the previous image, they can be joined in this way (the red line being how I want it to group them):
Does anybody have an idea?
code_1.dyn (30.5 KB)
The revit file is too heavy to load.