X-Git-Url: https://git.donarmstrong.com/?p=mothur.git;a=blobdiff_plain;f=rftreenode.hpp;h=d53cc2b614db5b1e9e8d8626127cd58d14bb0c0e;hp=8987ebcec58b04d8eaaff87e86f514887a4bfd17;hb=050a3ff02473a3d4c0980964e1a9ebe52e55d6b8;hpb=035f86272c776e1cccaa47021e26782e49cd41e7 diff --git a/rftreenode.hpp b/rftreenode.hpp index 8987ebc..d53cc2b 100755 --- a/rftreenode.hpp +++ b/rftreenode.hpp @@ -6,8 +6,8 @@ // Copyright (c) 2012 Schloss Lab. All rights reserved. // -#ifndef rrf_fs_prototype_treenode_hpp -#define rrf_fs_prototype_treenode_hpp +#ifndef RF_RFTREENODE_HPP +#define RF_RFTREENODE_HPP #include "mothurout.h" #include "macros.h" @@ -16,7 +16,14 @@ class RFTreeNode{ public: - RFTreeNode(vector< vector > bootstrappedTrainingSamples, vector globalDiscardedFeatureIndices, int numFeatures, int numSamples, int numOutputClasses, int generation); + RFTreeNode(vector< vector > bootstrappedTrainingSamples, + vector globalDiscardedFeatureIndices, + int numFeatures, + int numSamples, + int numOutputClasses, + int generation, + int nodeId, + float featureStandardDeviationThreshold = 0.0); virtual ~RFTreeNode(){} @@ -41,6 +48,7 @@ public: const vector& getBootstrappedOutputVector() { return bootstrappedOutputVector; } const vector& getFeatureSubsetIndices() { return featureSubsetIndices; } const double getOwnEntropy() { return ownEntropy; } + const int getTestSampleMisclassificationCount() { return testSampleMisclassificationCount; } // setters void setIsLeaf(bool isLeaf) { this->isLeaf = isLeaf; } @@ -77,6 +85,10 @@ private: double splitFeatureEntropy; double ownEntropy; + int nodeId; + float featureStandardDeviationThreshold; + int testSampleMisclassificationCount; + RFTreeNode* leftChildNode; RFTreeNode* rightChildNode; RFTreeNode* parentNode;