diff --git a/PWGLF/Tasks/Nuspex/antinucleiInJets.cxx b/PWGLF/Tasks/Nuspex/antinucleiInJets.cxx index 457a94ef26c..e8c866f7788 100644 --- a/PWGLF/Tasks/Nuspex/antinucleiInJets.cxx +++ b/PWGLF/Tasks/Nuspex/antinucleiInJets.cxx @@ -68,6 +68,7 @@ #include #include +#include #include #include #include @@ -203,6 +204,10 @@ struct AntinucleiInJets { // Number of events Configurable shrinkInterval{"shrinkInterval", 1000, "variable that controls how often shrinking happens"}; + // Range of systematic variations to be processed + Configurable systIndexStart{"systIndexStart", 0, "First systematic index (inclusive)"}; + Configurable systIndexEnd{"systIndexEnd", 50, "Last systematic index (exclusive)"}; + // Coalescence momentum Configurable coalescenceMomentum{"coalescenceMomentum", 0.15, "p0 (GeV/c)"}; @@ -3276,8 +3281,12 @@ struct AntinucleiInJets { static const std::vector ptOverAbins = {0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1.0}; const int nBins = ptOverAbins.size() - 1; + // Clamp systematic index range + const int systStart = std::max(0, static_cast(systIndexStart.value)); + const int systEnd = std::min(static_cast(nSyst), static_cast(systIndexEnd.value)); + // Loop over systematic variations - for (int isyst = 0; isyst < nSyst; isyst++) { + for (int isyst = systStart; isyst < systEnd; isyst++) { // Fill event counter for this systematic registryCorr.fill(HIST("eventCounter_centrality_fullEvent_syst"), multiplicity, static_cast(isyst));