0
$\begingroup$

So , thing is I was working on titanic dataset . During data preprocessing when i tried to use LabelEncoder I got the following error. Here X contains the train set while X1 contains the test set. As clear both train and test set are same . but code only works fine on test set while not train set. Anyone who can show me my mistake.

1st show the code . My code

2nd my dataset. My Dataset 3rd image shows my error. My Error

$\endgroup$
  • $\begingroup$ Check if your input is a list or of type None (meaning empty) $\endgroup$ – Peter Aug 11 at 18:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.