// @(#)root/tmva $Id$ // Author: Omar Zapata, Lorenzo Moneta, Sergei Gleyzer, Kim Albertsson /********************************************************************************** * Project: TMVA - a Root-integrated toolkit for multivariate data analysis * * Package: TMVA * * Class : ROCCurve * * * * Description: * * This is class to compute ROC Integral (AUC) * * * * Authors : * * Omar Zapata - UdeA/ITM Colombia * * Lorenzo Moneta - CERN, Switzerland * * Sergei Gleyzer - U of Florida & CERN * * Kim Albertsson - LTU & CERN * * * * Copyright (c) 2015: * * CERN, Switzerland * * UdeA/ITM, Colombia * * U. of Florida, USA * **********************************************************************************/ #ifndef ROOT_TMVA_ROCCurve #define ROOT_TMVA_ROCCurve #include "RtypesCore.h" #include #include #include class TList; class TTree; class TString; class TH1; class TH2; class TH2F; class TSpline; class TSpline1; class TGraph; namespace TMVA { class MsgLogger; class ROCCurve { public: ROCCurve(const std::vector> &mvas); ROCCurve(const std::vector &mvaValues, const std::vector &mvaTargets, const std::vector &mvaWeights); ROCCurve(const std::vector &mvaValues, const std::vector &mvaTargets); ROCCurve(const std::vector &mvaSignal, const std::vector &mvaBackground, const std::vector &mvaSignalWeights, const std::vector &mvaBackgroundWeights); ROCCurve(const std::vector &mvaSignal, const std::vector &mvaBackground); ~ROCCurve(); Double_t GetEffSForEffB(Double_t effB, const UInt_t num_points = 41); Double_t GetROCIntegral(const UInt_t points = 41); TGraph *GetROCCurve(const UInt_t points = 100); // n divisions = #points -1 const std::vector> GetMvas() const { return fMva; } private: mutable MsgLogger *fLogger; ///> fMva; std::vector ComputeSensitivity(const UInt_t num_points); std::vector ComputeSpecificity(const UInt_t num_points); }; } #endif