Lists and tuples allow us to group, sort, and filter through objects in Python as we would Grasshopper. As the data structure that we will use most, learn all the fundamentals of lists and their functions available. Also take a brief look at working with tuples.
- [Instructor] When working in Grasshopper,…it's more than likely you've come across…and used lists to store data such as…numbers, strings, or geometry.…A list is then simply a container…to store items in an ordered manner.…When working in Grasshopper,…if a component returns more than one item,…it is like a list or a tray containing lists.…Let's have a look at some of…the fundamentals of using lists in Python.…In a new Grasshopper file, let's go ahead…and place a Python component and…double click to open it up.…
Creating a list can be done in a few different ways.…The simplest method is by using…two square brackets, open, then closed.…This will create an empty list.…For example, let's create an empty list…by creating a variable named empty list…and I'll assign to this two square brackets,…open, then closed.…We now have an empty list which we can check…by printing out variable empty list and hit test…and there you can see our empty list.…
We can also create a list with predefined items.…For example, let's create a new variable…
- Python components
- Accessing the Rhino API
- Python programming basics
- Importing modules and libraries
- Grasshopper workflows
- Evaluating surfaces
- Creating and splitting surfaces
- Transforming geometry
- Baking geometry from Python into Rhino
- Adding text objects
- Exporting rendered frames for animation
Skill Level Intermediate
1. Working with Python
2. Python Basics
3. Importing Modules and Libraries
4. Grasshopper Workflows
Next steps3m 53s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.