Examples of PredictionNode


Examples of weka.classifiers.trees.adtree.PredictionNode

    m_negTrainInstances.compactify();

    // create the root prediction node
    double rootPredictionValue = calcPredictionValue(m_posTrainInstances,
                 m_negTrainInstances);
    m_root = new PredictionNode(rootPredictionValue);

    // pre-adjust weights
    updateWeights(m_posTrainInstances, m_negTrainInstances, rootPredictionValue);
   
    // pre-calculate what we can
View Full Code Here

Examples of weka.classifiers.trees.adtree.PredictionNode

      Instances posInstances =
  m_search_bestSplitter.instancesDownBranch(i, m_search_bestPathPosInstances);
      Instances negInstances =
  m_search_bestSplitter.instancesDownBranch(i, m_search_bestPathNegInstances);
      double predictionValue = calcPredictionValue(posInstances, negInstances);
      PredictionNode newPredictor = new PredictionNode(predictionValue);
      updateWeights(posInstances, negInstances, predictionValue);
      m_search_bestSplitter.setChildForBranch(i, newPredictor);
    }

    // insert the new nodes
View Full Code Here

Examples of weka.classifiers.trees.adtree.PredictionNode

  private void goDownZpurePathSingle(PredictionNode currentNode,
             Instances posInstances, Instances negInstances)
    throws Exception {

    double lowestZpure = m_search_smallestZ; // do z-pure cutoff
    PredictionNode bestPath = null;
    Instances bestPosSplit = null, bestNegSplit = null;

    // search for branch with lowest Z-pure
    for (Enumeration e = currentNode.children(); e.hasMoreElements(); ) {
      Splitter split = (Splitter) e.nextElement();
View Full Code Here

Examples of weka.classifiers.trees.adtree.PredictionNode

   
    for (Enumeration e = currentNode.children(); e.hasMoreElements(); ) {
      Splitter split = (Splitter) e.nextElement();
     
      for (int j=0; j<split.getNumOfBranches(); j++) {
  PredictionNode child = split.getChildForBranch(j);
  if (child != null) {
    text.append("\n");
    for (int k = 0; k < level; k++) {
      text.append("|  ");
    }
View Full Code Here

Examples of weka.classifiers.trees.adtree.PredictionNode

      " [style=dotted]\n");
      text.append("S" + split.orderAdded + " [label=\"" + split.orderAdded + ": " +
      split.attributeString(m_trainInstances) + "\"]\n");

      for (int i=0; i<split.getNumOfBranches(); i++) {
  PredictionNode child = split.getChildForBranch(i);
  if (child != null) {
    text.append("S" + split.orderAdded + "->" + "S" + split.orderAdded + "P" + i +
          " [label=\"" + split.comparisonString(i, m_trainInstances) + "\"]\n");
    graphTraverse(child, text, split.orderAdded, i,
      split.instancesDownBranch(i, instances));
View Full Code Here

Examples of weka.classifiers.trees.adtree.PredictionNode

    m_negTrainInstances.compactify();

    // create the root prediction node
    double rootPredictionValue = calcPredictionValue(m_posTrainInstances,
                 m_negTrainInstances);
    m_root = new PredictionNode(rootPredictionValue);

    // pre-adjust weights
    updateWeights(m_posTrainInstances, m_negTrainInstances, rootPredictionValue);
   
    // pre-calculate what we can
View Full Code Here

Examples of weka.classifiers.trees.adtree.PredictionNode

      Instances posInstances =
  m_search_bestSplitter.instancesDownBranch(i, m_search_bestPathPosInstances);
      Instances negInstances =
  m_search_bestSplitter.instancesDownBranch(i, m_search_bestPathNegInstances);
      double predictionValue = calcPredictionValue(posInstances, negInstances);
      PredictionNode newPredictor = new PredictionNode(predictionValue);
      updateWeights(posInstances, negInstances, predictionValue);
      m_search_bestSplitter.setChildForBranch(i, newPredictor);
    }

    // insert the new nodes
View Full Code Here

Examples of weka.classifiers.trees.adtree.PredictionNode

  private void goDownZpurePathSingle(PredictionNode currentNode,
             Instances posInstances, Instances negInstances)
    throws Exception {

    double lowestZpure = m_search_smallestZ; // do z-pure cutoff
    PredictionNode bestPath = null;
    Instances bestPosSplit = null, bestNegSplit = null;

    // search for branch with lowest Z-pure
    for (Enumeration e = currentNode.children(); e.hasMoreElements(); ) {
      Splitter split = (Splitter) e.nextElement();
View Full Code Here

Examples of weka.classifiers.trees.adtree.PredictionNode

   
    for (Enumeration e = currentNode.children(); e.hasMoreElements(); ) {
      Splitter split = (Splitter) e.nextElement();
     
      for (int j=0; j<split.getNumOfBranches(); j++) {
  PredictionNode child = split.getChildForBranch(j);
  if (child != null) {
    text.append("\n");
    for (int k = 0; k < level; k++) {
      text.append("|  ");
    }
View Full Code Here

Examples of weka.classifiers.trees.adtree.PredictionNode

      " [style=dotted]\n");
      text.append("S" + split.orderAdded + " [label=\"" + split.orderAdded + ": " +
      split.attributeString(m_trainInstances) + "\"]\n");

      for (int i=0; i<split.getNumOfBranches(); i++) {
  PredictionNode child = split.getChildForBranch(i);
  if (child != null) {
    text.append("S" + split.orderAdded + "->" + "S" + split.orderAdded + "P" + i +
          " [label=\"" + split.comparisonString(i, m_trainInstances) + "\"]\n");
    graphTraverse(child, text, split.orderAdded, i,
      split.instancesDownBranch(i, instances));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.