From 5f7159c8bacd4888cb1b4dd6b3a8becb1fcca5ce Mon Sep 17 00:00:00 2001 From: Francesca Ercolessi Date: Thu, 11 Jul 2024 15:20:21 +0200 Subject: [PATCH 1/2] Add event selections --- .../Strangeness/v0qaanalysis.cxx | 24 +++++++++++++------ 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/PWGLF/TableProducer/Strangeness/v0qaanalysis.cxx b/PWGLF/TableProducer/Strangeness/v0qaanalysis.cxx index 16b1ad7ebe6..469ba550859 100644 --- a/PWGLF/TableProducer/Strangeness/v0qaanalysis.cxx +++ b/PWGLF/TableProducer/Strangeness/v0qaanalysis.cxx @@ -66,14 +66,16 @@ struct LfV0qaanalysis { } LOG(info) << "Number of process functions enabled: " << nProc; - registry.add("hNEvents", "hNEvents", {HistType::kTH1I, {{8, 0.f, 8.f}}}); + registry.add("hNEvents", "hNEvents", {HistType::kTH1I, {{10, 0.f, 10.f}}}); registry.get(HIST("hNEvents"))->GetXaxis()->SetBinLabel(1, "all"); registry.get(HIST("hNEvents"))->GetXaxis()->SetBinLabel(2, "sel8"); registry.get(HIST("hNEvents"))->GetXaxis()->SetBinLabel(3, "TVX"); registry.get(HIST("hNEvents"))->GetXaxis()->SetBinLabel(4, "zvertex"); registry.get(HIST("hNEvents"))->GetXaxis()->SetBinLabel(5, "TFBorder"); registry.get(HIST("hNEvents"))->GetXaxis()->SetBinLabel(6, "ITSROFBorder"); - registry.get(HIST("hNEvents"))->GetXaxis()->SetBinLabel(7, "Applied selection"); + registry.get(HIST("hNEvents"))->GetXaxis()->SetBinLabel(7, "isTOFVertexMatched"); + registry.get(HIST("hNEvents"))->GetXaxis()->SetBinLabel(8, "isGoodZvtxFT0vsPV"); + registry.get(HIST("hNEvents"))->GetXaxis()->SetBinLabel(9, "Applied selection"); registry.add("hCentFT0M", "hCentFT0M", {HistType::kTH1F, {{1000, 0.f, 100.f}}}); registry.add("hCentFV0A", "hCentFV0A", {HistType::kTH1F, {{1000, 0.f, 100.f}}}); @@ -137,6 +139,8 @@ struct LfV0qaanalysis { Configurable isTriggerTVX{"isTriggerTVX", 1, "Is Trigger TVX"}; Configurable isNoTimeFrameBorder{"isNoTimeFrameBorder", 1, "Is No Time Frame Border"}; Configurable isNoITSROFrameBorder{"isNoITSROFrameBorder", 1, "Is No ITS Readout Frame Border"}; + Configurable isVertexTOFmatched{"isVertexTOFmatched", 0, "Is Vertex TOF matched"}; + Configurable isGoodZvtxFT0vsPV{"isGoodZvtxFT0vsPV", 0, "isGoodZvtxFT0vsPV"}; // V0 selection criteria Configurable v0cospa{"v0cospa", 0.97, "V0 CosPA"}; @@ -150,6 +154,7 @@ struct LfV0qaanalysis { template bool AcceptEvent(TCollision const& collision) { + registry.fill(HIST("hNEvents"), 0.5); if (sel8 && !collision.sel8()) { return false; } @@ -170,6 +175,14 @@ struct LfV0qaanalysis { return false; } registry.fill(HIST("hNEvents"), 5.5); + if (isVertexTOFmatched && !collision.selection_bit(aod::evsel::kVertexTOFmatched)) { + return false; + } + registry.fill(HIST("hNEvents"), 6.5); + if (isGoodZvtxFT0vsPV && !collision.selection_bit(aod::evsel::kIsGoodZvtxFT0vsPV)) { + return false; + } + registry.fill(HIST("hNEvents"), 7.5); return true; } @@ -183,11 +196,10 @@ struct LfV0qaanalysis { { // Apply event selection - registry.fill(HIST("hNEvents"), 0.5); if (!AcceptEvent(collision)) { return; } - registry.fill(HIST("hNEvents"), 6.5); + registry.fill(HIST("hNEvents"), 8.5); registry.fill(HIST("hCentFT0M"), collision.centFT0M()); registry.fill(HIST("hCentFV0A"), collision.centFV0A()); @@ -452,13 +464,11 @@ struct LfV0qaanalysis { //====== Event Split Numerator ======== //===================================== - registry.fill(HIST("hNEvents"), 0.5); registry.fill(HIST("hNEventsMCReco"), 0.5); if (!AcceptEvent(collision)) { continue; } - - registry.fill(HIST("hNEvents"), 6.5); + registry.fill(HIST("hNEvents"), 8.5); registry.fill(HIST("hNEventsMCReco"), 1.5); registry.fill(HIST("hCentFT0M_RecoColl_MC"), mcCollision.centFT0M()); From 7ea25aaa85855d12ede49910cd94682f59f34084 Mon Sep 17 00:00:00 2001 From: Francesca Ercolessi Date: Thu, 11 Jul 2024 16:20:25 +0200 Subject: [PATCH 2/2] fix --- PWGLF/TableProducer/Strangeness/v0qaanalysis.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PWGLF/TableProducer/Strangeness/v0qaanalysis.cxx b/PWGLF/TableProducer/Strangeness/v0qaanalysis.cxx index 469ba550859..875d0f1c671 100644 --- a/PWGLF/TableProducer/Strangeness/v0qaanalysis.cxx +++ b/PWGLF/TableProducer/Strangeness/v0qaanalysis.cxx @@ -175,7 +175,7 @@ struct LfV0qaanalysis { return false; } registry.fill(HIST("hNEvents"), 5.5); - if (isVertexTOFmatched && !collision.selection_bit(aod::evsel::kVertexTOFmatched)) { + if (isVertexTOFmatched && !collision.selection_bit(aod::evsel::kIsVertexTOFmatched)) { return false; } registry.fill(HIST("hNEvents"), 6.5);