for dataset in train_df: pd.to_numeric(dataset['Embarked'].map( {'S': 0, 'C': 1, 'Q': 2}))
TypeError Traceback (most recent call last) <ipython-input-41-9e474db5d734> in <module> 1 for dataset in train_df: ----> 2 pd.to_numeric(dataset['Embarked'].map( {'S': 0, 'C': 1, 'Q': 2})) TypeError: string indices must be integers
train_df
dataset
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)