Like and unlike sign selection
authorcvetan <cvetan@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 7 Mar 2013 13:58:42 +0000 (13:58 +0000)
committercvetan <cvetan@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 7 Mar 2013 13:58:42 +0000 (13:58 +0000)
PWGCF/Correlations/DPhi/MuonHadron/AliAnalysisTaskDiMuonCorrelations.cxx

index 3681799..39cc04d 100644 (file)
@@ -366,6 +366,13 @@ void AliAnalysisTaskDiMuonCorrelations::UserExec(Option_t *) {
 
 void AliAnalysisTaskDiMuonCorrelations::FillHistograms(Int_t centrality, Int_t option) {
 
+  if (fLikeSign) {
+    if ((fMuonTrack[0]->Charge()*fMuonTrack[1]->Charge()) <= 0) return;
+  }
+  else {
+    if ((fMuonTrack[0]->Charge()*fMuonTrack[1]->Charge()) >= 0) return;
+  }
+
   Int_t ptBinTrackMuon1 = fPtAxis -> FindBin(fMuonTrack[0]->Pt());
   Int_t ptBinTrackMuon2 = fPtAxis -> FindBin(fMuonTrack[1]->Pt());