class_docstr: Base class for testing frequent pattern mining on a small example.
class_docstr_tok: ["Base","class","for","testing","frequent","pattern","mining","on","a","small","example","."]
code: def setUp(self, fpalgo, one_ary=None):
      if one_ary is None:
          self.one_ary = np.array(
              [
                  [0, 0, 0, 1, 0, 1, 1, 1, 1, 0, 1],
                  [0, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1],
                  [1, 0, 0, 1, 0, 1, 1, 0, 0, 0, 0],
                  [0, 1, 0, 0, 0, 1, 1, 0, 0, 1, 1],
                  [0, 1, 0, 1, 1, 1, 0, 0, 1, 0, 0],
              ]
          )
      else:
          self.one_ary = one_ary
  
      self.cols = [
          "Apple",
          "Corn",
          "Dill",
          "Eggs",
          "Ice cream",
          "Kidney Beans",
          "Milk",
          "Nutmeg",
          "Onion",
          "Unicorn",
          "Yogurt",
      ]
  
      self.df = pd.DataFrame(self.one_ary, columns=self.cols)
  
      self.fpalgo = fpalgo
  
imports: import sys
  from contextlib import contextmanager
  from io import StringIO
  import numpy
  import pandas
  from numpy.testing import assert_array_equal
  from packaging.version import Version
  from pandas import __version__
  from scipy.sparse import csr_matrix
  from mlxtend.preprocessing import TransactionEncoder
  from mlxtend.utils import assert_raises
label_desc: Use image node_id 1 for calling the FPTestEx1 obj's underlying member method code with example usage: obj.setUp(fpalgo, one_ary) without return types