hey hanye huang, sorry for the late late reply. Found your question while answering another one. Indeed, there’s something wrong with the code, thanks for flagging! It comes up ‘sum(a,b)’ adds up all the elements of a to each one one of the elements of b individually. What we want to do there is the following:

mean_ab = np.sum(a+b)/4

Thanks again for flagging! I’ll be correcting this on the story asap. This is what happens when you rely too much on technology and don’t even check the easiest math :).

Cheers

    Gonzalo Ferreiro Volpi

    Written by

    ELI5 DATA: Explain Like I’m 5 | Just a guy trying to make data simpler | Data Science @ Ravelin | Fancy joining my mailing list? 👉🏻http://eepurl.com/gA_rkj