File indexing completed on 2025-01-18 10:11:03
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022
0023
0024
0025
0026
0027
0028 #ifndef ROOT_TMVA_Ranking
0029 #define ROOT_TMVA_Ranking
0030
0031
0032
0033
0034
0035
0036
0037
0038
0039 #include <vector>
0040
0041 #include "TString.h"
0042
0043 namespace TMVA {
0044
0045 class MsgLogger;
0046 class Rank;
0047
0048 class Ranking {
0049
0050 public:
0051
0052 Ranking();
0053 Ranking( const TString& context, const TString& rankingDiscriminatorName );
0054 virtual ~Ranking();
0055
0056 virtual void AddRank( const Rank& rank );
0057 virtual void Print() const;
0058
0059 void SetContext ( const TString& context );
0060 void SetDiscrName( const TString& discrName ) { fRankingDiscriminatorName = discrName; }
0061
0062 private:
0063
0064 std::vector<TMVA::Rank> fRanking;
0065 TString fContext;
0066 TString fRankingDiscriminatorName;
0067
0068 mutable MsgLogger* fLogger;
0069 MsgLogger& Log() const { return *fLogger; }
0070
0071 ClassDef(Ranking,0);
0072 };
0073
0074
0075
0076 class Rank {
0077
0078 public:
0079
0080 Rank( const TString& variable, Double_t rankValue );
0081 virtual ~Rank();
0082
0083
0084 Bool_t operator < ( const Rank& other ) const;
0085 Bool_t operator > ( const Rank& other ) const;
0086
0087 const TString& GetVariable() const { return fVariable; }
0088 Double_t GetRankValue() const { return fRankValue; }
0089 Int_t GetRank() const { return fRank; }
0090 void SetRank( Int_t rank ) { fRank = rank; }
0091
0092 private:
0093
0094 TString fVariable;
0095 Double_t fRankValue;
0096
0097 Int_t fRank;
0098 };
0099 }
0100
0101 #endif