Feb-27-2021, 02:31 PM
code
Hi,
I still see nulls in X_train and my pipline seems to not have applied. For example, there should be more columns due to one-hot encoding. Am I doing something wrong?
Hi,
I still see nulls in X_train and my pipline seems to not have applied. For example, there should be more columns due to one-hot encoding. Am I doing something wrong?
def apply_fe_pipeline(X_train,X_test): # fit the imputer feature_engineering_pipeline.fit(X_train) # transform the data X_train= feature_engineering_pipeline.transform(X_train) X_test= feature_engineering_pipeline.transform(X_test) training_null=X_train.isna().values.sum() test_null=X_test.isna().values.sum() return print ('count of nulls in training set after fe:',training_null, 'count of nulls in test set after fe:',test_null)
apply_fe_pipeline(X_train,X_test)