Grasshopper

algorithmic modeling for Rhino

I am working with data from a .txt file that has a (y) point for every second (x). I was able to partition the list so that for every minute (60secs) the data is split. Then I have a simple nurbs curve through those points as a first step to visualize the data. 

I am having trouble splitting the line and moving the vector to a new x,y coordinate so I can organize each line that represents 60 data points.

Is there a way to pull from the partitioned data tree without having to repeat a command for every list item #? maybe a loop or another list command...

I have attached my .gh, .txt, and .3dm and hopefully this is just a quick fix!

(In the Rhino file I have an example of what I am trying to achieve in grasshopper, but I manually moved each curve after baking.)

Thanks in advance,

Juliana

Views: 1175

Replies to This Discussion

You can plug in a sets>sequence command into your vector. And plug in the 60 seconds slider on the left of your screenshot into the Count input. This will create 60 numbers. (0 to 59 in a list)
Then plug it into the vector input instead of the manual sliders. You may need to graft the output vectors if the paths don't match
Looking at the raw text file, you may wish to use Sets>text>split which has two inputs, the first input is the text file, the second the the character to split by(the comma). This will then create each second as a tree branch which has two leaves. Index 0 will be seconds, index 1 will be volts. Path{0;0} will be 0 seconds, path {0;1} will be 1 second, {0;2} will be 2 seconds etc...

You can then retrieve all index 0s (the second values) using Lists>list item (index set to 0) and the same again for volts (set to 1)

Hi.

Is this What you are after?

Attachments:

Make them to a circle and offset X-direction and loft? I don't understand what you mean.

You mean "Z" direction? not "X".

Something like this? I'm not sure...

Attachments:

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service