build/lib/AutoMxL/Preprocessing/Missing_Values.py
def transform(self, df, verbose=False):
        """ transform dataset categorical features using the encoder.
        Can be done only if encoder has been fitted

        Parameters
        ----------
        df : DataFrame
            dataset to transform
        verbose : boolean (Default False)
            Get logging information
        """
        assert self.is_fitted, 'fit the encoding first using .fit method'

        df_local = df.copy()

        # categorical features filling
        if len(self.l_var_cat) > 0:
            df_local = fill_categorical(df_local, l_var=self.l_var_cat, method=self.replace_cat_with,
                                        verbose=verbose)

        # numerical features filling
        if len(self.l_var_num) > 0:
            df_local = fill_numerical(df_local, l_var=self.l_var_num, method=self.replace_num_with,
                                      track_num_NA=self.track_num_NA, verbose=verbose)

        # if no feature to fill
        if len(self.l_var_cat) + len(self.l_var_num) == 0 and verbose:
            print("  > no transformation to apply")

        return df_local
 transform dataset categorical features using the encoder.
        Can be done only if encoder has been fitted

        Parameters
        ----------
        df : DataFrame
            dataset to transform
        verbose : boolean (Default False)
            Get logging information
        
transform dataset categorical features using the encoder.
Can be done only if encoder has been fitted

Parameters

df : DataFrame
dataset to transform
verbose : boolean (Default False)
Get logging information
transform dataset categorical features using the encoder . Can be done only if encoder has been fitted Parameters df : DataFrame dataset to transform verbose : boolean ( Default False ) Get logging information
def transform(self, df, verbose=False):
        assert self.is_fitted, 'fit the encoding first using .fit method'
        df_local = df.copy()
        if len(self.l_var_cat) > 0:
            df_local = fill_categorical(df_local, l_var=self.l_var_cat, method=self.replace_cat_with,
                                        verbose=verbose)
        if len(self.l_var_num) > 0:
            df_local = fill_numerical(df_local, l_var=self.l_var_num, method=self.replace_num_with,
                                      track_num_NA=self.track_num_NA, verbose=verbose)
        if len(self.l_var_cat) + len(self.l_var_num) == 0 and verbose:
            print("  > no transformation to apply")
        return df_local
def transform ( self , df , verbose = False ) : assert self . is_fitted , 'fit the encoding first using .fit method' df_local = df . copy ( ) if len ( self . l_var_cat ) > 0 : df_local = fill_categorical ( df_local , l_var = self . l_var_cat , method = self . replace_cat_with , verbose = verbose ) if len ( self . l_var_num ) > 0 : df_local = fill_numerical ( df_local , l_var = self . l_var_num , method = self . replace_num_with , track_num_NA = self . track_num_NA , verbose = verbose ) if len ( self . l_var_cat ) + len ( self . l_var_num ) == 0 and verbose : print ( "  > no transformation to apply" ) return df_local
transform dataset categorical features using the encoder.
transform dataset categorical features using the encoder .
""" transform dataset categorical features using the encoder.
        Can be done only if encoder has been fitted

        Parameters
        ----------
        df : DataFrame
            dataset to transform
        verbose : boolean (Default False)
            Get logging information
        """ # categorical features filling # numerical features filling # if no feature to fill
self
df
verbose