Documentation of 'jhpro.dtree.DecisionTree' Java class
DecisionTree
jhpro.dtree

Class DecisionTree

  • All Implemented Interfaces:
    java.io.Serializable


    public class DecisionTree
    extends java.lang.Object
    implements java.io.Serializable
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor and Description
      DecisionTree()
      Default constructor of the tree.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      void addNoNode(int existingNodeID, int newNodeID, java.lang.String newQuestAns)
      Add NO mode to the tree.
      void addYesNode(int existingNodeID, int newNodeID, java.lang.String newQuestAns)
      Add YES to this node.
      void createRoot(int newNodeID, java.lang.String newQuestAns)
      Create ROOT of the tree.
      java.lang.String outputBinTree()
      Show the tree as a string
      BinTree queryBinTree(BinTree currentNode)
      Query the tree for a given node
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • rootNode

        public static BinTree rootNode
      • description

        public java.lang.String description
    • Constructor Detail

      • DecisionTree

        public DecisionTree()
        Default constructor of the tree.
    • Method Detail

      • createRoot

        public void createRoot(int newNodeID,
                               java.lang.String newQuestAns)
        Create ROOT of the tree.
      • addYesNode

        public void addYesNode(int existingNodeID,
                               int newNodeID,
                               java.lang.String newQuestAns)
        Add YES to this node.
      • addNoNode

        public void addNoNode(int existingNodeID,
                              int newNodeID,
                              java.lang.String newQuestAns)
        Add NO mode to the tree.
      • queryBinTree

        public BinTree queryBinTree(BinTree currentNode)
                             throws java.io.IOException
        Query the tree for a given node
        Parameters:
        currentNode - current node.
        Throws:
        java.io.IOException
      • outputBinTree

        public java.lang.String outputBinTree()
        Show the tree as a string

DMelt 3.0 © DataMelt by jWork.ORG

Ads help maintain this website.