node item at index - blossommerz/locus-hub GitHub Wiki
< Previous: Flatten | Next: List Length >
Pull one item out of a list by its position (0-based; negative counts from the end).
Category: Data | Add menu: Data > Item at Index
- List (any): the list to pull an item out of.
- Index (number): which item to pull, 0-based (negative counts from the end). A list of indices pulls one item per index, see below.
- Item (any): the single item at that index, or a list of items when Index is a list.
Wire a single number into Index and you get one item out. Wire a list of numbers in and Item at Index picks one item per index and returns the whole set, in the order the indices came.
That is what makes a per-item pick possible: a Series of seeds through Random gives a list of indices, and that list through Item at Index gives a different item for every position. Feeding a color list in that way is how each item in a collection ends up with its own color.
Geometry items are not the only thing it reads. A plain list of colors, numbers or strings, the kind Collect produces from non-geometry inputs, indexes by position under the same contract: 0-based, negative counting from the end.
< Previous: Flatten | Next: List Length >
Points inside a group are not items of their own: they travel with the member they belong to. See Lists & collections.
- Collect: build the list to index into | List Length - how many items there are, which bounds the Index.
- Lists & collections | Data nodes

