Lists allow you to group, sort, and filter through objects in Python as you would Dynamo. As the data structure that you will use most, learn all the fundamentals of lists and their functions available to you.
- [Instructor] While working in Dynamo,…you're probably more than experienced at using lists…to store numbers, geometry or Revit elements.…A list is used to store objects in an ordered manner.…In Dynamo, all data outputting from nodes…that is more than one item is essentially a list.…Let's have a look at some of the fundamentals…of using lists in Python.…As you can see, I've created a new Dynamo file,…so let's go ahead and place a new Python Script node.…Creating a list can be done in a few ways,…the simplest method is to use square brackets…to create an empty list.…
For example, let's create an empty list…by creating the variable name lst…and we'll assign to it two square brackets.…We now have an empty list…which we can check by outputting our variable.…We can also create a list with predefined items.…For example, let's create a list variable lstnums…and this time, we'll assign to it…the numbers zero through to four, separated by commas.…The commas are used to separate our objects…as separate items in the list.…
Note: This course uses Dynamo 1.3.1 and Revit 2018. For best results, it helps to have the same versions of the software.
- Importing the Dynamo Geometry library
- Defining variables
- Making decisions with conditionals
- Controlling flow with operators
- Defining functions
- Working with external libraries in Python
- Accessing the Revit API with Python
Skill Level Beginner
1. Dynamo and Python
2. Python Basics
3. Working with Libraries
4. Revit API
Next steps2m 18s
- 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.