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()
static TClass*Class()
UInt_tCountNodes(TMVA::Node* n = NULL)
virtual TMVA::Node*CreateNode()
TMVA::Node*GetLeftDaughter(TMVA::Node* n)
UInt_tGetNNodes() const
TMVA::Node*GetRightDaughter(TMVA::Node* n)
TMVA::Node*GetRoot() const
UInt_tGetTotalTreeDepth() const
virtual TClass*IsA() const
voidPrint(ostream& os) const
voidRead(istream& istr)
voidSetRoot(TMVA::Node* r)
voidSetTotalTreeDepth(Int_t depth)
voidSetTotalTreeDepth(TMVA::Node* n = NULL)
virtual voidShowMembers(TMemberInspector& insp, char* parent)
virtual voidStreamer(TBuffer& b)
voidStreamerNVirtual(TBuffer& b)
protected:
voidDeleteNode(TMVA::Node*)

Data Members

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

Class Charts

Inheritance Inherited Members Includes Libraries
Class Charts

Function documentation

~BinaryTree( void )
destructor (deletes the nodes and "events" if owned by the tree
void DeleteNode(TMVA::Node* )
 protected, recursive, function used by the class destructor and when Pruning
TMVA::Node* GetLeftDaughter(TMVA::Node* n)
 get left daughter node current node "n"
TMVA::Node* GetRightDaughter(TMVA::Node* n)
 get right daughter node current node "n"
UInt_t CountNodes(TMVA::Node* n = NULL)
 return the number of nodes in the tree. (make a new count --> takes time)
void Print(ostream& os) const
 recursively print the tree
void Read(istream& istr)
 Read the binary tree from an input stream.
 The input stream format depends on the tree type,
 it is defined be the node of the tree
void SetTotalTreeDepth( Node *n)
 descend a tree to find all its leaf nodes, fill max depth reached in the
 tree at the same time.
Node* CreateNode()
void SetRoot(TMVA::Node* r)
 set the root node of the tree
{ fRoot = r; }
Node* GetRoot()
 Retrieves the address of the root node
{ return fRoot; }
UInt_t GetNNodes()
 get number of Nodes in the Tree as counted while booking the nodes;
{ return fNNodes; }
UInt_t GetTotalTreeDepth()
{ return fDepth; }
void SetTotalTreeDepth( Int_t depth )
{ fDepth = depth;}

Author: Andreas Hoecker, Joerg Stelzer, Helge Voss, Kai Voss
Last change: root/tmva $Id: BinaryTree.h 21630 2008-01-10 19:40:44Z brun $
Last generated: 2008-06-25 08:48
Copyright (c) 2005: *

This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.