From 9bcfb287881e3fce35618128c94bc8e6e19b7d78 Mon Sep 17 00:00:00 2001 From: cnattras Date: Fri, 4 Jul 2014 15:01:19 -0400 Subject: [PATCH] updating calculation of secondary correction to include making latex tables for analysis note and fix fitting problem with PHOS data --- PWGLF/totEt/macros/emEt/PlotSecondariesCorr.C | 25 +++++++++++-------- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/PWGLF/totEt/macros/emEt/PlotSecondariesCorr.C b/PWGLF/totEt/macros/emEt/PlotSecondariesCorr.C index 4b45d44541f..d48801290cc 100644 --- a/PWGLF/totEt/macros/emEt/PlotSecondariesCorr.C +++ b/PWGLF/totEt/macros/emEt/PlotSecondariesCorr.C @@ -257,7 +257,7 @@ void PlotSecondariesCorr(TString filename = "rootFiles/LHC11a10a_bis/Et.ESD.simP nSecondariesShortClMultScaledSim[currentShortCB] += neventsBinn*meanet; neventsShort[0] +=neventsBinn; } - nSecondariesClMultScaledSim[cb] = nSecondariesClMultScaledSim[cb]/nevents; + if(nevents>0) nSecondariesClMultScaledSim[cb] = nSecondariesClMultScaledSim[cb]/nevents; @@ -272,7 +272,7 @@ void PlotSecondariesCorr(TString filename = "rootFiles/LHC11a10a_bis/Et.ESD.simP nSecondariesShortTrMultScaledSim[currentShortCB] += neventsBinn*meanet; neventsShort[1] +=neventsBinn; } - nSecondariesTrMultScaledSim[cb] = nSecondariesTrMultScaledSim[cb]/nevents; + if(nevents>0) nSecondariesTrMultScaledSim[cb] = nSecondariesTrMultScaledSim[cb]/nevents; nbins = ((TH1*)clustermultiplicity[cb])->GetNbinsX(); nevents = 0.0; @@ -289,11 +289,11 @@ void PlotSecondariesCorr(TString filename = "rootFiles/LHC11a10a_bis/Et.ESD.simP nSecondariesShortClMultScaledData[currentShortCB] += neventsBinn*meanet; neventsShort[2] +=neventsBinn; } - meanmult = meanmult/nevents; + if(nevents>0) meanmult = meanmult/nevents; //nSecondariesClMultScaledData[cb] = nSecondariesClMultScaledData[cb]/nevents; //cout<<")/"<0) nSecondariesClMultScaledData[cb] = nSecondariesClMultScaledData[cb]/nevents;//<<" = "; //cout<<" " << nSecondariesClMultScaledData[cb]; //cout<<" mean "<<((TH1*)clustermultiplicityData[cb])->GetMean()<<" mean2 "<GetBinContent(profNCl->FindBin(meanmult)); //cout<<" mean method "<< profNCl->GetBinContent(profNCl->FindBin(((TH1*)trackmultiplicityData[cb])->GetMean())); @@ -312,7 +312,7 @@ void PlotSecondariesCorr(TString filename = "rootFiles/LHC11a10a_bis/Et.ESD.simP } // cout<<"cb "<0) nSecondariesTrMultScaledData[cb] = nSecondariesTrMultScaledData[cb]/nevents; // cout<<" " << nSecondariesTrMultScaledData[cb]; // cout<<" mean "<<((TH1*)trackmultiplicityData[cb])->GetMean()<<" mean method "<< profNCh->GetBinContent(profNCh->FindBin(((TH1*)trackmultiplicityData[cb])->GetMean())); // cout<