class_docstr: EXPERIMENTAL
  
  AutoGluon InterpretableTabularPredictor predicts values in a column of a tabular dataset (classification or regression).
  InterpretableTabularPredictor shares the same functionality as TabularPredictor, but is limited to simple models
  that are easier to interpret visually via simple rules.
  
  InterpretableTabularPredictor should be used when accuracy is not important,
  and instead interpretability is the key requirement.
  
  Categorical features are one-hot-encoded to preserve interpretability.
  
  Stacking and bagging are not available in this predictor to preserve interpretability.
docstr: Explain classification errors by fitting a rule-based model to them
  
  Parameters
  ----------
  data : str or :class:`TabularDataset` or :class:`pd.DataFrame`
      The data to make predictions for. Should contain same column names as training Dataset and follow same format
      (may contain extra columns that won't be used by Predictor, including the label-column itself).
      If str is passed, `data` will be loaded using the str value as the file path.
  model : str (optional)
      The name of the model to get predictions from. Defaults to None, which uses the highest scoring model on the validation set.
      Valid models are listed in this `predictor` by calling `predictor.model_names()`
  print_rules : bool, optional
      Whether to print the learned rules
  
  Returns
  -------
  cls : imodels.classifier
      Interpretable rule-based classifier with fit/predict methods
docstr_tok: ["Explain","classification","errors","by","fitting","a","rule-based","model","to","them","Parameters","--","--","--","--","--","data",":","str","or",":","class",":","`","TabularDataset","`","or",":","class",":","`","pd.DataFrame","`","The","data","to","make","predictions","for",".","Should","contain","same","column","names","as","training","Dataset","and","follow","same","format","(","may","contain","extra","columns","that","wo","n't","be","used","by","Predictor",",","including","the","label-column","itself",")",".","If","str","is","passed",",","`","data","`","will","be","loaded","using","the","str","value","as","the","file","path",".","model",":","str","(","optional",")","The","name","of","the","model","to","get","predictions","from",".","Defaults","to","None",",","which","uses","the","highest","scoring","model","on","the","validation","set",".","Valid","models","are","listed","in","this","`","predictor","`","by","calling","`","predictor.model_names","(",")","`","print_rules",":","bool",",","optional","Whether","to","print","the","learned","rules","Returns","--","--","--","-","cls",":","imodels.classifier","Interpretable","rule-based","classifier","with","fit\/predict","methods"]
code: def explain_classification_errors(
      self, data, model=None, print_rules: bool = True
  ):
      """Explain classification errors by fitting a rule-based model to them
  
      Parameters
      ----------
      data : str or :class:`TabularDataset` or :class:`pd.DataFrame`
          The data to make predictions for. Should contain same column names as training Dataset and follow same format
          (may contain extra columns that won't be used by Predictor, including the label-column itself).
          If str is passed, `data` will be loaded using the str value as the file path.
      model : str (optional)
          The name of the model to get predictions from. Defaults to None, which uses the highest scoring model on the validation set.
          Valid models are listed in this `predictor` by calling `predictor.model_names()`
      print_rules : bool, optional
          Whether to print the learned rules
  
      Returns
      -------
      cls : imodels.classifier
          Interpretable rule-based classifier with fit/predict methods
      """
      import imodels
  
      if model is None:
          model = self.model_best
      data = self._get_dataset(data)
      predictions = self.predict(data=data, model=model, as_pandas=True)
      labels = data[self.label]
      data_transformed = self.transform_features(data=data, model=model)
      labels_transformed = self.transform_labels(labels=labels)
      cls, columns = imodels.explain_classification_errors(
          data_transformed,
          predictions,
          labels_transformed,
          print_rules=print_rules,
      )
      return cls
  
file_path: autogluon/tabular/src/autogluon/tabular/predictor/interpretable_predictor.py
imports: import logging
  import numpy
  import pandas
  from .predictor import TabularPredictor
label_desc: Use image node_id 5 for calling the InterpretableTabularPredictor obj's underlying member method code with example usage: obj.explain_classification_errors(data, model, print_rules) and returns: cls