mult seelction in pp according to AnalysisUtils
authorlmilano <lmilano@cern.ch>
Mon, 1 Sep 2014 07:45:41 +0000 (09:45 +0200)
committerlmilano <lmilano@cern.ch>
Mon, 1 Sep 2014 07:45:41 +0000 (09:45 +0200)
PWGCF/Correlations/DPhi/AliAnalysisTaskPhiCorrelations.cxx

index c52ea2f..bff2a9a 100644 (file)
@@ -509,6 +509,11 @@ void  AliAnalysisTaskPhiCorrelations::AnalyseCorrectionMode()
     {
       centrality = (Float_t) gROOT->ProcessLine(Form("100.0 + 100.0 * ((AliNanoAODHeader*) %p)->GetCentrality(\"%s\")", fAOD->GetHeader(), fCentralityMethod.Data())) / 100 - 1.0;
     }
+    else if (fCentralityMethod == "PPVsMultUtils")
+      {
+       if(fAnalysisUtils)centrality=fAnalysisUtils->GetMultiplicityPercentile((fAOD)?(AliVEvent*)fAOD:(AliVEvent*)fESD);
+       else centrality = -1;
+    }
     else
     {
       AliCentrality *centralityObj = 0;
@@ -1093,7 +1098,12 @@ void  AliAnalysisTaskPhiCorrelations::AnalyseDataMode()
       if (error != TInterpreter::kNoError)
        centrality = -1;
     }
-    else
+   else if (fCentralityMethod == "PPVsMultUtils")
+     {
+       if(fAnalysisUtils)centrality=fAnalysisUtils->GetMultiplicityPercentile((fAOD)?(AliVEvent*)fAOD:(AliVEvent*)fESD);
+       else centrality = -1;
+    }
+   else
     {
       if (fAOD)
        centralityObj = fAOD->GetHeader()->GetCentralityP();