Skip to content

Commit 71292db

Browse files
authored
enable LS counting for +ve and -ve
1 parent 33a836d commit 71292db

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

PWGLF/TableProducer/Nuspex/ebyeMaker.cxx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@ struct EbyeMaker {
201201
Configurable<float> etaMaxV0dau{"etaMaxV0dau", 0.8f, "maximum eta V0 daughters"};
202202
Configurable<float> outerPIDMin{"outerPIDMin", -4.f, "minimum outer PID"};
203203

204-
Configurable<bool> countOnlyNegTrk{"countOnlyNegTrk", false, "count only negative tracks in Ntracks"};
204+
Configurable<uint8_t> countOnlyLSTrk{"countOnlyLSTrk", 0, "count only like sign tracks in Ntracks: 0 -> +ve and -ve; 1 -> -ve; 2 -> +ve"};
205205
Configurable<bool> useAllEvSel{"useAllEvSel", false, "use additional event selections fo run 3 analyses"};
206206
Configurable<uint8_t> triggerCut{"triggerCut", 0x0, "trigger cut to select"};
207207
Configurable<bool> kINT7Intervals{"kINT7Intervals", false, "toggle kINT7 trigger selection in the 10-30% and 50-90% centrality intervals (2018 Pb-Pb)"};
@@ -571,7 +571,7 @@ struct EbyeMaker {
571571
continue;
572572
}
573573
histos.fill(HIST("QA/tpcSignal"), track.tpcInnerParam(), track.tpcSignal());
574-
if (trackPt > ptMin[0] && trackPt < ptMax[0] && ((track.sign() < 0 && countOnlyNegTrk) || !countOnlyNegTrk))
574+
if (trackPt > ptMin[0] && trackPt < ptMax[0] && ((track.sign() < 0 && countOnlyLSTrk == 1) || (track.sign() > 0 && countOnlyLSTrk == 2) || (countOnlyLSTrk == 0)))
575575
nTracksColl++;
576576

577577
for (int iP{0}; iP < kNpart; ++iP) {
@@ -856,7 +856,7 @@ struct EbyeMaker {
856856
auto genPt = std::hypot(mcPart.px(), mcPart.py());
857857
if ((std::abs(pdgCode) == PDG_t::kPiPlus || std::abs(pdgCode) == PDG_t::kElectron || std::abs(pdgCode) == PDG_t::kMuonMinus || std::abs(pdgCode) == PDG_t::kKPlus || std::abs(pdgCode) == PDG_t::kProton) && mcPart.isPhysicalPrimary() && genPt > ptMin[0] && genPt < ptMax[0]) {
858858
int ch = (pdgCode == PDG_t::kPiPlus || pdgCode == -PDG_t::kElectron || pdgCode == -PDG_t::kMuonMinus || pdgCode == PDG_t::kKPlus || pdgCode == PDG_t::kProton) ? 1 : -1;
859-
if ((ch < 0 && countOnlyNegTrk) || !countOnlyNegTrk)
859+
if ((ch < 0 && countOnlyLSTrk == 1) || (ch > 0 && countOnlyLSTrk == 2) || (countOnlyLSTrk == 0))
860860
nChPartGen++;
861861
}
862862
if (std::abs(pdgCode) == PDG_t::kLambda0) {

0 commit comments

Comments
 (0)