A++ » TMVA » TMVA::BinaryTree

class TMVA::BinaryTree


BinaryTree

Base class for BinarySearch and Decision Trees


Function Members (Methods)

 
    This is an abstract class, constructors will not be documented.
    Look at the header to check for available constructors.

public:
virtual~BinaryTree()
virtual void*AddXMLTo(void* parent) const
TMVA::BinaryTreeBinaryTree()
TMVA::BinaryTreeBinaryTree(const TMVA::BinaryTree&)
static TClass*Class()
virtual const char*ClassName() const
UInt_tCountNodes(TMVA::Node* n = __null)
virtual TMVA::Node*CreateNode(UInt_t size = 0) const
virtual TMVA::BinaryTree*CreateTree() const
TMVA::Node*GetLeftDaughter(TMVA::Node* n)
UInt_tGetNNodes() const
TMVA::Node*GetRightDaughter(TMVA::Node* n)
virtual TMVA::Node*GetRoot() const
UInt_tGetTotalTreeDepth() const
virtual TClass*IsA() const
TMVA::BinaryTree&operator=(const TMVA::BinaryTree&)
virtual voidPrint(ostream& os) const
virtual voidRead(istream& istr, UInt_t tmva_Version_Code = 262657)
virtual voidReadXML(void* node, UInt_t tmva_Version_Code = 262657)
voidSetRoot(TMVA::Node* r)
voidSetTotalTreeDepth(Int_t depth)
voidSetTotalTreeDepth(TMVA::Node* n = __null)
virtual voidShowMembers(TMemberInspector& insp) const
virtual voidStreamer(TBuffer&)
voidStreamerNVirtual(TBuffer& ClassDef_StreamerNVirtual_b)
protected:
voidDeleteNode(TMVA::Node*)
TMVA::MsgLogger&Log() const

Data Members

protected:
UInt_tfDepthmaximal depth in tree reached
UInt_tfNNodestotal number of nodes in the tree (counted)
TMVA::Node*fRootthe root node of the tree

Class Charts

Inheritance Chart:
TMVA::BinaryTree
TMVA::BinarySearchTree
TMVA::DecisionTree

Function documentation

BinaryTree(const TMVA::BinaryTree& )
 or a tree with Root node "n", any daughters of this node are automatically in the tree
virtual ~BinaryTree()
Node* CreateNode(UInt_t size = 0) const
BinaryTree* CreateTree() const
      virtual BinaryTree* CreateFromXML(void* node, UInt_t tmva_Version_Code = TMVA_VERSION_CODE) = 0;
const char* ClassName() const
void SetRoot(TMVA::Node* r)
 set the root node of the tree
{ fRoot = r; }
Node* GetRoot() const
 Retrieves the address of the root node
{ return fRoot; }
UInt_t GetNNodes() const
 get number of Nodes in the Tree as counted while booking the nodes;
{ return fNNodes; }
UInt_t CountNodes(TMVA::Node* n = __null)
 count the number of Nodes in the Tree by looping through the tree and updates
 the stored number. (e.g. useful when pruning, as the number count is updated when
 building the tree.
UInt_t GetTotalTreeDepth() const
{ return fDepth; }
void SetTotalTreeDepth(Int_t depth)
{ fDepth = depth; }
void SetTotalTreeDepth(TMVA::Node* n = __null)
Node* GetLeftDaughter(TMVA::Node* n)
Node* GetRightDaughter(TMVA::Node* n)
void Print(ostream& os) const
void Read(istream& istr, UInt_t tmva_Version_Code = 262657)
void* AddXMLTo(void* parent) const
void ReadXML(void* node, UInt_t tmva_Version_Code = 262657)
void DeleteNode(TMVA::Node* )
 the tree only has it's root node, the "daughters" are taken car
 of by the "node" properties of the "root"
 delete a node (and the corresponding event if owned by the tree)