Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
ResultsClassification.h
Go to the documentation of this file.
1// @(#)root/tmva $Id$
2// Author: Andreas Hoecker, Peter Speckmayer, Joerg Stelzer, Helge Voss
3
4/**********************************************************************************
5 * Project: TMVA - a Root-integrated toolkit for multivariate data analysis *
6 * Package: TMVA *
7 * Class : ResultsClassification *
8 * *
9 * *
10 * Description: *
11 * Derived-class for result-vectors *
12 * *
13 * Authors (alphabetical): *
14 * Andreas Hoecker <Andreas.Hocker@cern.ch> - CERN, Switzerland *
15 * Peter Speckmayer <Peter.Speckmayer@cern.ch> - CERN, Switzerland *
16 * Joerg Stelzer <Joerg.Stelzer@cern.ch> - CERN, Switzerland *
17 * Helge Voss <Helge.Voss@cern.ch> - MPI-K Heidelberg, Germany *
18 * *
19 * Copyright (c) 2006: *
20 * CERN, Switzerland *
21 * U. of Victoria, Canada *
22 * MPI-K Heidelberg, Germany *
23 * *
24 * Redistribution and use in source and binary forms, with or without *
25 * modification, are permitted according to the terms listed in LICENSE *
26 * (see tmva/doc/LICENSE) *
27 **********************************************************************************/
28
29#ifndef ROOT_TMVA_ResultsClassification
30#define ROOT_TMVA_ResultsClassification
31
32//////////////////////////////////////////////////////////////////////////
33// //
34// ResultsClassification //
35// //
36// Class that is the derived-class for a vector of results //
37// //
38//////////////////////////////////////////////////////////////////////////
39
40#include <vector>
41
42#include "TMVA/Results.h"
43
44namespace TMVA {
45
46class MsgLogger;
47
49
50public:
51 ResultsClassification(const DataSetInfo *dsi, TString resultsName);
53
54 // setters : set score value and type for each single event.
55 // note type=TRUE for signal and FLASE for background
57
58 void Resize(Int_t entries)
59 {
60 fMvaValues.resize(entries);
61 fMvaValuesTypes.resize(entries);
62 }
63 using TObject::Clear;
64 void Clear(Option_t *) override
65 {
66 fMvaValues.clear();
67 fMvaValuesTypes.clear();
68 }
69
70 // getters
71 Long64_t GetSize() const { return fMvaValues.size(); }
72 const std::vector<Float_t> &operator[](Int_t ievt) const override
73 {
74 fRet[0] = fMvaValues[ievt];
75 return fRet;
76 }
77 std::vector<Float_t> *GetValueVector() { return &fMvaValues; }
78 std::vector<Bool_t> *GetValueVectorTypes() { return &fMvaValuesTypes; }
79
81
82private:
83 std::vector<Float_t> fMvaValues; ///< mva values (Results)
84 std::vector<Bool_t> fMvaValuesTypes; ///< mva values type(sig/bkg) (Results)
85 mutable std::vector<Float_t> fRet; ///< return val
86 mutable MsgLogger *fLogger; ///<! message logger
87 MsgLogger &Log() const { return *fLogger; }
88
89protected:
91};
92} // namespace TMVA
93
94#endif
float Float_t
Definition RtypesCore.h:57
long long Long64_t
Definition RtypesCore.h:69
const char Option_t
Definition RtypesCore.h:66
#define ClassDefOverride(name, id)
Definition Rtypes.h:346
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void value
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
Class that contains all the data information.
Definition DataSetInfo.h:62
ostringstream derivative to redirect and format output
Definition MsgLogger.h:57
Class that is the base-class for a vector of result.
Types::EAnalysisType GetAnalysisType() override
const std::vector< Float_t > & operator[](Int_t ievt) const override
std::vector< Bool_t > * GetValueVectorTypes()
std::vector< Float_t > * GetValueVector()
std::vector< Float_t > fMvaValues
mva values (Results)
std::vector< Float_t > fRet
return val
std::vector< Bool_t > fMvaValuesTypes
mva values type(sig/bkg) (Results)
void SetValue(Float_t value, Int_t ievt, Bool_t type)
set MVA response
void Clear(Option_t *) override
MsgLogger * fLogger
! message logger
Class that is the base-class for a vector of result.
Definition Results.h:57
@ kClassification
Definition Types.h:127
virtual void Clear(Option_t *="")
Definition TObject.h:119
Basic string class.
Definition TString.h:139
create variable transformations