class_docstr: An estimator that supports building rules as described in
  A Simple, Fast, and Effective Rule Learner (1999). Intended to be used
  as part of the SlipperRulesClassifier.
class_docstr_tok: ["An","estimator","that","supports","building","rules","as","described","in","A","Simple",",","Fast",",","and","Effective","Rule","Learner","(","1999",")",".","Intended","to","be","used","as","part","of","the","SlipperRulesClassifier","."]
docstr: Make the default rule that is true for every observation
  of data set. Without default rule a SlipperBaseEstimator would never
  predict negative
docstr_tok: ["Make","the","default","rule","that","is","true","for","every","observation","of","data","set",".","Without","default","rule","a","SlipperBaseEstimator","would","never","predict","negative"]
code: def _make_default_rule(self, X, y):
      """
      Make the default rule that is true for every observation
      of data set. Without default rule a SlipperBaseEstimator would never
      predict negative
      """
      default_rule = []
      features = random.choices(
          range(X.shape[1]), k=random.randint(2, 8)
      )
  
      default_rule.append(
          {
              "feature": str(features[0]),
              "operator": ">",
              "pivot": str(min(X[:, features[0]])),
          }
      )
  
      for i, x in enumerate(features):
          if i % 2:
              default_rule.append(
                  {
                      "feature": x,
                      "operator": "<",
                      "pivot": str(max(X[:, x])),
                  }
              )
          else:
              default_rule.append(
                  {
                      "feature": x,
                      "operator": ">",
                      "pivot": str(min(X[:, x])),
                  }
              )
  
      return default_rule
  
imports: import random
  import numpy
  from sklearn.base import BaseEstimator, ClassifierMixin
  from sklearn.model_selection import train_test_split
  from imodels.util.arguments import check_fit_arguments
label_desc: Use image node_id 11 for calling the SlipperBaseEstimator obj's underlying member method code with example usage: obj._make_default_rule(X, y) and returns: default_rule