Loading [MathJax]/extensions/tex2jax.js
ROOT
6.06/09
Reference Guide
ROOT Home Page
Main Page
Related Pages
User's Classes
Namespaces
All Classes
Files
Release Notes
File List
File Members
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Modules
Pages
tmva
tmva
src
BDTEventWrapper.cxx
Go to the documentation of this file.
1
/**********************************************************************************
2
* Project: TMVA - a Root-integrated toolkit for multivariate data analysis *
3
* Package: TMVA *
4
* Class : BDTEventWrapper *
5
* Web : http://tmva.sourceforge.net *
6
* *
7
* Description: *
8
* *
9
* *
10
* Author: Doug Schouten (dschoute@sfu.ca) *
11
* *
12
* *
13
* Copyright (c) 2007: *
14
* CERN, Switzerland *
15
* MPI-K Heidelberg, Germany *
16
* U. of Texas at Austin, USA *
17
* *
18
* Redistribution and use in source and binary forms, with or without *
19
* modification, are permitted according to the terms listed in LICENSE *
20
* (http://tmva.sourceforge.net/LICENSE) *
21
**********************************************************************************/
22
23
#ifndef ROOT_TMVA_BDTEventWrapper
24
#include "
TMVA/BDTEventWrapper.h
"
25
#endif
26
27
using namespace
TMVA
;
28
29
BDTEventWrapper::BDTEventWrapper
(
const
Event
* e) : fEvent(e) {
30
// constuctor
31
32
fBkgWeight
= 0.0;
33
fSigWeight
= 0.0;
34
}
35
36
BDTEventWrapper::~BDTEventWrapper
() {
37
// destructor
38
}
39
40
void
BDTEventWrapper::SetCumulativeWeight
(
Bool_t
type
,
Double_t
weight) {
41
// Set the accumulated weight, for sorted signal/background events
42
/**
43
* @param fType - true for signal, false for background
44
* @param weight - the total weight
45
*/
46
47
if
(type)
fSigWeight
= weight;
48
else
fBkgWeight
= weight;
49
}
50
51
Double_t
BDTEventWrapper::GetCumulativeWeight
(
Bool_t
type
)
const
{
52
// Get the accumulated weight
53
54
if
(type)
return
fSigWeight
;
55
return
fBkgWeight
;
56
}
BDTEventWrapper.h
TMVA::BDTEventWrapper::fBkgWeight
Double_t fBkgWeight
Definition:
BDTEventWrapper.h:76
Bool_t
bool Bool_t
Definition:
RtypesCore.h:59
TMVA::BDTEventWrapper::BDTEventWrapper
BDTEventWrapper(const Event *)
Definition:
BDTEventWrapper.cxx:29
TMVA::Event
Definition:
Event.h:57
TMVA::BDTEventWrapper::fSigWeight
Double_t fSigWeight
Definition:
BDTEventWrapper.h:77
TMVA::BDTEventWrapper::GetCumulativeWeight
Double_t GetCumulativeWeight(Bool_t type) const
Definition:
BDTEventWrapper.cxx:51
Double_t
double Double_t
Definition:
RtypesCore.h:55
TMVA::BDTEventWrapper::~BDTEventWrapper
~BDTEventWrapper()
Definition:
BDTEventWrapper.cxx:36
type
int type
Definition:
TGX11.cxx:120
TMVA
Abstract ClassifierFactory template that handles arbitrary types.
Definition:
MethodPyAdaBoost.h:29
TMVA::BDTEventWrapper::SetCumulativeWeight
void SetCumulativeWeight(Bool_t type, Double_t weight)
Definition:
BDTEventWrapper.cxx:40