class_docstr: Сlass for storing, cleaning and processing your dataset
class_docstr_tok: ["\u0421lass","for","storing",",","cleaning","and","processing","your","dataset"]
docstr: Fill Nans and add column, that there were nans in this column
  
  Args:
      data (pd.DataFrame, shape (n_samples, n_features)): the input data
      cols list() features: the input data
  Return:
      Clean data (pd.DataFrame, shape (n_samples, n_features))
docstr_tok: ["Fill","Nans","and","add","column",",","that","there","were","nans","in","this","column","Args",":","data","(","pd.DataFrame",",","shape","(","n_samples",",","n_features",")",")",":","the","input","data","cols","list","(",")","features",":","the","input","data","Return",":","Clean","data","(","pd.DataFrame",",","shape","(","n_samples",",","n_features",")",")"]
code: def clean_nans(self, data, cols=None):
      """
      Fill Nans and add column, that there were nans in this column
  
      Args:
          data (pd.DataFrame, shape (n_samples, n_features)): the input data
          cols list() features: the input data
      Return:
          Clean data (pd.DataFrame, shape (n_samples, n_features))
  
      """
      if cols is not None:
          nan_columns = list(
              data[cols].columns[data[cols].isnull().sum() > 0]
          )
          if nan_columns:
              for nan_column in nan_columns:
                  data[nan_column + "_isNAN"] = pd.isna(
                      data[nan_column]
                  ).astype("uint8")
              data.fillna(data.median(), inplace=True)
      return data
  
imports: import pandas
  import numpy
  from itertools import combinations
  from sklearn.preprocessing import StandardScaler
  from category_encoders import HashingEncoder, SumEncoder, PolynomialEncoder, BackwardDifferenceEncoder
  from category_encoders import OneHotEncoder, HelmertEncoder, OrdinalEncoder, CountEncoder, BaseNEncoder
  from category_encoders import TargetEncoder, CatBoostEncoder, WOEEncoder, JamesSteinEncoder
  from category_encoders.glmm import GLMMEncoder
  from sklearn.preprocessing import LabelEncoder
  from category_encoders.wrapper import PolynomialWrapper
  from .encoders import FrequencyEncoder
  from .None import settings
  import pdb
  import copy
  import dask
  import dask.dataframe
label_desc: Use image node_id 3 for calling the DataBunch obj's underlying member method code with example usage: obj.clean_nans(data, cols) and returns: data