30 #ifndef ROOT_TMVA_BinarySearchTree 31 #define ROOT_TMVA_BinarySearchTree 79 virtual const char*
ClassName()
const {
return "BinarySearchTree"; }
105 Double_t Fill(
const std::vector<TMVA::Event*>& events,
const std::vector<Int_t>& theVars,
Int_t theType = -1 );
148 void NormalizeTree( std::vector< std::pair< Double_t, const TMVA::Event* > >::iterator,
149 std::vector< std::pair< Double_t, const TMVA::Event* > >::iterator,
UInt_t );
153 std::vector<const TMVA::BinarySearchTreeNode*>* events );
Int_t SearchVolumeWithMaxLimit(TMVA::Volume *, std::vector< const TMVA::BinarySearchTreeNode *> *events=0, Int_t=-1)
recursively walk through the daughter nodes and add up all weights of events that lie within the give...
std::vector< Double_t > fSum[2]
BinarySearchTreeNode * Search(Event *event) const
search the tree to find the node matching "event"
virtual Node * CreateNode(UInt_t) const
std::vector< Float_t > fMax[2]
std::vector< Double_t > fSumSq[2]
#define TMVA_VERSION_CODE
virtual ~BinarySearchTree(void)
destructor
Bool_t InVolume(const std::vector< Float_t > &, Volume *) const
test if the data points are in the given volume
virtual BinaryTree * CreateTree() const
Double_t Fill(const std::vector< TMVA::Event *> &events, const std::vector< Int_t > &theVars, Int_t theType=-1)
create the search tree from the event collection using ONLY the variables specified in "theVars" ...
Node for the BinarySearch or Decision Trees.
Double_t GetSumOfWeights(void) const
return the sum of event (node) weights
UInt_t GetPeriode(void) const
Volume for BinarySearchTree.
void NormalizeTree()
Normalisation of tree.
std::vector< std::pair< Double_t, const TMVA::Event * > > fNormalizeTreeTable
Base class for BinarySearch and Decision Trees.
#define ClassDef(name, id)
void Clear(TMVA::Node *n=0)
clear nodes
void CalcStatistics(TMVA::Node *n=0)
calculate basic statistics (mean, rms for each variable)
Bool_t fStatisticsIsValid
BinarySearchTree(void)
default constructor
static BinarySearchTree * CreateFromXML(void *node, UInt_t tmva_Version_Code=TMVA_VERSION_CODE)
re-create a new tree (decision tree or search tree) from XML
Float_t Max(Types::ESBType sb, UInt_t var)
Float_t Min(Types::ESBType sb, UInt_t var)
void SetNormalize(Bool_t norm)
void Insert(const Event *)
insert a new "event" in the binary tree
Float_t RMS(Types::ESBType sb, UInt_t var)
std::vector< Float_t > fMeans[2]
Float_t Mean(Types::ESBType sb, UInt_t var)
Abstract ClassifierFactory template that handles arbitrary types.
Node for the BinarySearch or Decision Trees.
void DestroyNode(BinarySearchTreeNode *)
virtual const char * ClassName() const
you should not use this method at all Int_t Int_t Double_t Double_t Double_t Int_t Double_t Double_t Double_t Double_t b
A TTree object has a header with a name and a title.
std::vector< Float_t > fMin[2]
Double_t SearchVolume(Volume *, std::vector< const TMVA::BinarySearchTreeNode *> *events=0)
search the whole tree and add up all weights of events that lie within the given volume ...
std::vector< Float_t > fRMS[2]
double norm(double *x, double *p)
A simple Binary search tree including a volume search method.