class_docstr: Encodes rare categories into an "other" parameter.
  
  Note that this encoder assumes data is received as a DataFrame.
  
  Parameters
  ----------
  max_num_categories : int , default: 10
      Indicates the maximum number of unique categories in a single categorical column
      (rare categories will be changed to a form of "other")
  cols : Optional[List[Hashable]] , default: None
      Columns to limit the encoder to work on. If non are given will work on all columns given in `fit`
class_docstr_tok: ["Encodes","rare","categories","into","an","``","other","''","parameter",".","Note","that","this","encoder","assumes","data","is","received","as","a","DataFrame",".","Parameters","--","--","--","--","--","max_num_categories",":","int",",","default",":","10","Indicates","the","maximum","number","of","unique","categories","in","a","single","categorical","column","(","rare","categories","will","be","changed","to","a","form","of","``","other","''",")","cols",":","Optional","[","List","[","Hashable","]","]",",","default",":","None","Columns","to","limit","the","encoder","to","work","on",".","If","non","are","given","will","work","on","all","columns","given","in","`","fit","`"]
code: def _get_unique_other_value(self, series: pd.Series):
      unique_values = list(series.unique())
      other = self.DEFAULT_OTHER_VALUE
      i = 0
      while other in unique_values:
          other = self.DEFAULT_OTHER_VALUE + str(i)
          i += 1
      return other
  
file_path: deepchecks/deepchecks/utils/distribution/rare_category_encoder.py
imports: from collections import defaultdict
  from typing import List, Optional
  import pandas
  from deepchecks.utils.typing import Hashable
label_desc: Use image node_id 6 for calling the RareCategoryEncoder obj's underlying member method code with example usage: obj._get_unique_other_value(series) and returns: other