Error in Week 10 Quiz Explained (Optional)

In Question number 7 I am getting an error. Below is the attached screen shot.

Please explain what is wrong ?

I think Y[‘Age’] is a mistake/typo in the quiz.
Y['Age'] = df['Age'] is probably Y = df['Age']

Note that df[Age] is a Series object as mentioned in the answer (though its assignment to Y[‘Age’] is incorrectly written)

1 Like

Yes! Now its working fine. Thank You.