Quantopian's community platform is shutting down. Please read this post for more information and download your code.
Back to Community
How to loop through multiple securities?

I've gone through a few of the algorithms written here, but I'm still not entirely sure how to loop through multiple securities. The 'Data' object seems to handle it, but I'm not clear how exactly it's done.

Furthermore, can I reference each individual security as an index? ie. context.stocks[1]

Thank you

1 response