I am a new user of Grasshopper. Currently, I am working to get consecutive distance values among the list of 3D point which I have imported as a list in Gh-Python Script.!
Any Help will be appreciated!
Thank you and have a nice day!
Importing a list of 3D point as an input to GH-Python script and the distance among consecutive points
I’m not sure if this is the most efficient way, but maybe it will help you out.
ConsecPointDistance.gh (3.9 KB)
Here are two slightly different approaches (both using RhinoCommon directly):
190513_PointListDistances_00.gh (8.3 KB)
Also, it helps a lot if you post your files when posting
@Adam_M Thank you very much for your help but unfortunately, the code I am running on the data imported from excel to the panel is not working.
Also, I am copy pasting large amount of data from excel into the panel window, but it is only displaying 815 entries, why is that? how to overcome this problem?. The Grasshopper and Excel files are attached here. Can you help me a little more?
Thanks a lot.
ConsecPointDistance.gh (18.7 KB)
@AndersDeleuran Thank you for your help but the problem is still there. The issue is the same as I discussed in my above reply to @Adam_M. I wonder if you can figure out the same problems?
And yes I upload my file from this time onwards.
Thanks a lot.
190513_PointListDistances_00.gh (22.9 KB)
You are missing the Z values in the last line of copied data.
Note: I think you could also read this direct from excel, or a csv file. There are components for this in LunchBox.
Can you please highlight? What else is required? because I think I am providing all the coordinates.
Oh, Thank you so much. The panel is not accepting any Z value on 815, I guess it has researched the limit. Now your code is running perfectly, but again, I have to read the use of lunch box.
Thanks a lot for your help.
One last question from both of you @Adam_M and @AndersDeleuran. I want to learn Rhino with grasshopper plug-in and also with GH-python scripting. So from where should I start?
I mean, is it necessary to get knowledge about rhino first and practice to get perfect and after rhino, start learning Grasshopper? or both can be learnt simultaneous?
Also for GH-python scripting, Do i need to have strong command on Python programming language?
And from where can I get sufficient knowledge about the different libraries and functions used in GH-Python scripting?
Your expert advises will be helpful for me.
A good place to start is here:
That said, I would recommend sticking to implementing
RhinoCommon directly in GHPython for geometry based scripting (most of those pages implement the
rhinoscriptsyntax Python module, which is a wrapper around RhinoCommon, targeting the Rhino document). But either way, should get you going.
@AndersDeleuran Thank you once again.