Grasshopper

algorithmic modeling for Rhino

Hello,

I'm trying to use Elk to create a city massing model. I've selected the list item "building:levels:#" from the OSM data and now I am wondering how I can extract the number to multiply by ten feet or so to get a rough building height.  Some of the more monumental buildings have a year in the list item instead so I need to set a larger than and just replace it with a 1 or something and manually mass them in Rhino.

Thank you so much for any help!        

Views: 4702

Replies to This Discussion

I tried using fragment to get to the last item in the string, which kind of works.

Here is the OSM map data.

Attachments:

Something like that? You can use the text split command and select the integer, which as it seems is always indexed "2". Then you can use the "larger than" test for chronologies!

This works perfectly, some of the buildings that are more significant, like cathedrals have text instead of number of levels.  I was wondering if it was possible to have if "text" replace with "#"

Thanks for taking the time to help! 

For those of us who don't have Elk installed, can you internalize this data so we might help you parse it?

Of course, here's the file with the list and polylines internalized

Attachments:

you are faster than light!

Would have been better to internalize the data as a 'Data' param instead of the input to a 'List Item'.  I managed to reconstruct the complete data list, then use 'TMatch' to find the lines containing "building:levels", then parsed those lines by splitting them on ":".

Attachments:

Fantastic, Thanks !

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service