Grasshopper

algorithmic modeling for Rhino

I have a range of numbers between 0-1. I want to make the data set be a list with only the values .9 and .1. or x and y.

I want a simple relationship, like anything above .5 will be replaced with x (.9 in image) and anything below .5 will be replaced with y(.1 in image). Obviously i want to be able to tweak the rules so it can be any combo, like anything above or below .3 will become .7 and .o1 etc. I have tried cull but the problem is when i recombine the lists they are not in the right order. I need to evaluate line by line and keep the parametric relationship. The image shows the list of numbers i have on the left, and and example of the desired list on the right (i made it manual). this is killing me. lol, my midterm is on wednesday and this is the last piece of the puzzle, any help will be treasured!

Views: 505

Attachments:

Replies to This Discussion

Ok...so i might have figured out a way.

Using the strucure that i now have, i simply need to lists, one full of .1's and one full of .9's to feed into the weave. However, how the crap do i just make a list of .1's and .9's???
Attachments:
This should do the trick. It just uses a list of booleans to duplicate two different numbers and then weaves those two sets of numbers back together based on the booleans. I just used a random list of numbers here.
Attachments:
haha , cool. I did it a totally different way, but thanks for helping!

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service