Skip to content
Snippets Groups Projects
Commit b7831309 authored by Marshall Scott's avatar Marshall Scott
Browse files

Added count function 2

parent 218d8c0e
No related branches found
No related tags found
1 merge request!37Fix pions
This commit is part of merge request !29. Comments created here will be created in the context of that merge request.
......@@ -64,7 +64,8 @@ void emcal_barrel_pions_electrons_analysis(const char* input_fname = "sim_output
int count = 0;
if (input[2].pdgID == 11)// Electron
{
for (const auto& i: evt && count > 1)
for (const auto& i: evt)
if (count > 0) continue;
total_edep += i.energyDeposit;
count++;
}
......@@ -79,7 +80,8 @@ void emcal_barrel_pions_electrons_analysis(const char* input_fname = "sim_output
int count = 0;
if (input[2].pdgID == -211)// Negative pion
{
for (const auto& i: evt && count < 1)
for (const auto& i: evt)
if (count > 0) continue;
total_edep += i.energyDeposit;
count++;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment