You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Let's update the usage of missing value handling to make it more user friendly. The update would apply to all transformers that handle missing values. Currently, these are:
BooleanTransformer
DateTimeTransformer (+ variants)
NumericalTransformer (+ variants)
NullTransformer
Expected behavior
nan becomes missing_value_replacement, with updated defaults
# (default) do not replace missing valuesnt=NumericalTransformer()
# replace with a static numbernt=NumericalTransformer(missing_value_replacement=0.00)
# replace using a methodnt=NumericalTransformer(missing_value_replacement='mode')
null_column becomes model_missing_values that can only accept True/False values; updated functionality & defaults
# (default = False) do not create a new columnnt=NumericalTransformer()
nt=NumericalTransformer(model_missing_values=False)
# True creates a missing column if there is missing datant=NumericalTransformer(model_missing_values=True)
nt.fit(data, columns=['column_with_missing_values'])
# otherwise do not create a column and warn the usernt=NumericalTransformer(model_missing_values=True)
nt.fit(data, columns=['never_null_column'])
Guidance: Therearenomissingvaluesincolumn'never_null_column'. Extracolumnnotcreated.
The text was updated successfully, but these errors were encountered:
This issue will probably have to be completed at the same as Update NullTransformer to make it user friendly #372 since all these transformers call the NullTransformer behind the scenes, so they will crash if the parameters for the NullTransformer change and theirs don't
Since each transformer will be using the same parameters to define how the NullTransformer will be used, perhaps it makes sense to move them to the BaseTransformer class. On top of that, we may want to call the NullTransformer from within the BaseTransformer'sfit, transform and reverse_transform methods. Something like
Problem Description
Let's update the usage of missing value handling to make it more user friendly. The update would apply to all transformers that handle missing values. Currently, these are:
BooleanTransformer
DateTimeTransformer
(+ variants)NumericalTransformer
(+ variants)NullTransformer
Expected behavior
nan
becomesmissing_value_replacement
, with updated defaultsnull_column
becomesmodel_missing_values
that can only accept True/False values; updated functionality & defaultsThe text was updated successfully, but these errors were encountered: