Quantopian's community platform is shutting down. Please read this post for more information and download your code.
Back to Community
UnderstandingSample tutorial 1 Momentum algorithm syntax

Hi! I'm going over the Tutorial 1 sample momentum algorithm and am having trouble understanding the syntax of this line:

buys = buys.iloc[:buy_length] if buy_weight != 0 else None

Specifically, I'm wondering about the use of the colon in [:buy_length].
Thanks!