Hello I don't know where to report this so I'll just write it here. I found a mistake in notebook Quantopian Lecture Series: Discrete and Continuous Random Variables.
In the area where W portfolio gets calculated, the Y_weight is calculated wrong because it returns 0 while it should return float point number.
Y_quantity = 20
Z_quantity = 50
Y_weight = Y_quantity/(Y_quantity + Z_quantity)
This obviously isn't 0.
Solution to this could be:
Y_weight = Y_quantity/((Y_quantity + Z_quantity)*1.0)
Now plotting of W portfolio makes sense because before it was equal to Z stock, since Y_weight was counted as 0 :)
Thank you