Grasshopper

algorithmic modeling for Rhino

Hi,

I would like to take a text document that continuously being updated and stream it live to grasshopper. I would like to compare the incoming words to a list of predefined words and find out if there is a match.

I managed to read the data into grasshopper (see screenshot), but I am not sure how to now separate the words and compare them to a list.

I would greatly appreciate any advise regarding textual interpretation in grasshopper!

Views: 1523

Replies to This Discussion

Hello

you could try the following

it uses text split component and the separator is one space. then you can test for one or more words and find if there are in the text with text match, resulting in true or false, or test if the words is in the text, at what index in the list it is, with member index component. the rest has to do with what data structure you want to have.

cheers

alex

Hi Alex,

thank you, that is exactly what I needed. Since you seem to know about text input- have you ever tried streaming live text into grasshopper?
At the moment the only way to update the definition is to manually save the document each time. I was wondering if there is a way one could type into a document and it would automatically update in grasshopper.

Thanks again!!

Bika

Hi Bika,

This is not a Grasshopper-related issue.

If the file is not saved (I am guessing it is a .txt but the same applies to any file) it doesn't actually contain the changes you have made. 

So you could try some of the suggestions found here: http://www.makeuseof.com/answers/auto-save-text-files-custom-time-i...

good luck with your project,

Nikos

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service