accumulate csvreader input #1244
Answered
by
bruno-f-cruz
emilyjanedennis
asked this question in
Q&A
-
hiya, attempting to do something that should be easy but isn't clear how to beat go about it... I'd like to use CsvReader and accumulate the rows into a list (or array or whatever) and then use that list/array/whatever in a python transform node... any hints? Scan seems promising but without an example is hard for me to figure out how to use... thanks! |
Beta Was this translation helpful? Give feedback.
Answered by
bruno-f-cruz
Feb 8, 2023
Replies: 1 comment
-
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
emilyjanedennis
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Heya,
In general, you can use the
ToArray
operator to create arrays of any type. This operator packages a full sequence (it must be successfully terminated) into a single array. A good practice is then to store this array in some subject with memory. E.g.:Whenever you want to use it, get the value from it and pass it to the next operator:
Regarding the
PythonTransform
, this will likely change in the new future as we are working on a new Python package for Bonsai, but for now here's an example on how you could manipulate the array:Arrays_Python.zip
…