parameters: ()
docstring: testing code for named trees
  
      The created pkl file is required by the unit test code.
docstring_summary: testing code for named trees
docstring_tokens: testing code for named trees
function: def TestQuantTree2():  # pragma: nocover
      """ testing code for named trees
  
      The created pkl file is required by the unit test code.
      """
      examples1 = [['p1', 0.1, 1, 0.1, 0], ['p2', 0.1, 0, 0.1, 1], ['p3', 0.1, 0, 1.1, 2],
                   ['p4', 0.1, 1, 1.1, 2], ['p5', 1.1, 0, 0.1, 2], ['p6', 1.1, 0, 1.1, 2],
                   ['p7', 1.1, 1, 0.1, 2], ['p8', 1.1, 1, 1.1, 0]]
      attrs = list(range(1, len(examples1[0]) - 1))
      nPossibleVals = [0, 0, 2, 0, 3]
      boundsPerVar = [0, 1, 0, 1, 0]
  
      t1 = QuantTreeBoot(examples1, attrs, nPossibleVals, boundsPerVar)
      t1.Print()
      t1.Pickle('test_data/QuantTree2.pkl')
  
      for example in examples1:
          print(example, t1.ClassifyExample(example))
function_tokens: def TestQuantTree2 ( ) : # pragma: nocover examples1 = [ [ 'p1' , 0.1 , 1 , 0.1 , 0 ] , [ 'p2' , 0.1 , 0 , 0.1 , 1 ] , [ 'p3' , 0.1 , 0 , 1.1 , 2 ] , [ 'p4' , 0.1 , 1 , 1.1 , 2 ] , [ 'p5' , 1.1 , 0 , 0.1 , 2 ] , [ 'p6' , 1.1 , 0 , 1.1 , 2 ] , [ 'p7' , 1.1 , 1 , 0.1 , 2 ] , [ 'p8' , 1.1 , 1 , 1.1 , 0 ] ] attrs = list ( range ( 1 , len ( examples1 [ 0 ] ) - 1 ) ) nPossibleVals = [ 0 , 0 , 2 , 0 , 3 ] boundsPerVar = [ 0 , 1 , 0 , 1 , 0 ] t1 = QuantTreeBoot ( examples1 , attrs , nPossibleVals , boundsPerVar ) t1 . Print ( ) t1 . Pickle ( 'test_data/QuantTree2.pkl' ) for example in examples1 : print ( example , t1 . ClassifyExample ( example ) )