From 023d615982ad3e78baa32edee2e26cea3fff527a Mon Sep 17 00:00:00 2001 From: Christian Pulvermacher Date: Fri, 27 Feb 2015 17:09:16 +0100 Subject: [PATCH] Update TMVA scripts for ROOT6 --- tmva/test/CorrGui.C | 6 +++--- tmva/test/paracoor.C | 11 +++++++++-- tmva/test/probas.C | 8 +++++--- 3 files changed, 17 insertions(+), 8 deletions(-) diff --git a/tmva/test/CorrGui.C b/tmva/test/CorrGui.C index 8279c840678b3..f68553d1f973d 100644 --- a/tmva/test/CorrGui.C +++ b/tmva/test/CorrGui.C @@ -45,8 +45,8 @@ void CorrGui( TString fin = "TMVA.root", TString dirName = "InputVariables_Id", // how many variables are in the directory? Int_t noVar = TMVAGlob::GetNumberOfInputVariables(dir); - cout << "found number of variables='" << noVar<< endl; - TString Var[noVar]; + cout << "found number of variables: " << noVar<< endl; + vector Var(noVar); TIter next(dir->GetListOfKeys()); Int_t it=0; @@ -69,7 +69,7 @@ void CorrGui( TString fin = "TMVA.root", TString dirName = "InputVariables_Id", } } } - cout << "found histos for "<< it <<" variables='" << endl; + cout << "found histos for "<< it <<" variables." << endl; for (Int_t ic=0;icAddButton( (Var[ic].Contains("_target") ? diff --git a/tmva/test/paracoor.C b/tmva/test/paracoor.C index 27d5cfa0d213a..03e6e20271197 100644 --- a/tmva/test/paracoor.C +++ b/tmva/test/paracoor.C @@ -1,5 +1,12 @@ #include "tmvaglob.C" +#include "TParallelCoord.h" +#include "TParallelCoordVar.h" +#include "TParallelCoordRange.h" +#include "TTree.h" +#include "TLeaf.h" +#include "TFile.h" + // plot parallel coordinates void paracoor( TString fin = "TMVA.root", Bool_t useTMVAStyle = kTRUE ) @@ -45,14 +52,14 @@ void paracoor( TString fin = "TMVA.root", Bool_t useTMVAStyle = kTRUE ) const Int_t nmva = mvas.size(); TCanvas* csig[nmva]; TCanvas* cbkg[nmva]; - for (Int_t imva=0; imvaReadObj(); TString hname= th1->GetName(); if (hname.Contains( suffixSig ) && !hname.Contains( "Cut") && @@ -147,7 +149,7 @@ void probas( TString fin = "TMVA.root", Bool_t useTMVAStyle = kTRUE ) Float_t ymin = 0; Float_t ymax = TMath::Max( sig->GetMaximum(), bgd->GetMaximum() )*1.5; - if (Draw_CFANN_Logy && mvaName[imva] == "CFANN") ymin = 0.01; + if (Draw_CFANN_Logy && methodTitle == "CFANN") ymin = 0.01; // build a frame Int_t nb = 500; @@ -160,7 +162,7 @@ void probas( TString fin = "TMVA.root", Bool_t useTMVAStyle = kTRUE ) // eventually: draw the frame frame->Draw(); - if (Draw_CFANN_Logy && mvaName[imva] == "CFANN") c->SetLogy(); + if (Draw_CFANN_Logy && methodTitle == "CFANN") c->SetLogy(); // overlay signal and background histograms sig->SetMarkerColor( TMVAGlob::c_SignalLine );