Logo ROOT  
Reference Guide
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
24
25/*! \class TMVA::BDTEventWrapper
26\ingroup TMVA
27*/
28
29#include "RtypesCore.h"
30
31using namespace TMVA;
32
33////////////////////////////////////////////////////////////////////////////////
34/// Constructor.
35
36BDTEventWrapper::BDTEventWrapper(const Event* e) : fEvent(e) {
37
38 fBkgWeight = 0.0;
39 fSigWeight = 0.0;
40}
41
42////////////////////////////////////////////////////////////////////////////////
43/// Destructor.
44
46}
47
48////////////////////////////////////////////////////////////////////////////////
49/// Set the accumulated weight, for sorted signal/background events
50///
51/// @param type - true for signal, false for background
52/// @param weight - the total weight
53
55
56
57 if(type) fSigWeight = weight;
58 else fBkgWeight = weight;
59}
60
61////////////////////////////////////////////////////////////////////////////////
62/// Get the accumulated weight
63
65 if(type) return fSigWeight;
66 return fBkgWeight;
67}
#define e(i)
Definition: RSha256.hxx:103
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t Atom_t Atom_t Time_t type
~BDTEventWrapper()
Destructor.
void SetCumulativeWeight(Bool_t type, Double_t weight)
Set the accumulated weight, for sorted signal/background events.
Double_t fBkgWeight
cumulative background weight for splitting
Double_t fSigWeight
same for the signal weights
Double_t GetCumulativeWeight(Bool_t type) const
Get the accumulated weight.
create variable transformations