How could specified decay model be chosen?

Dear all,
I want to simulate the gamma decay of Tl-208 in TPC with SeF6 gas. But beta decay and gamma decay are existed. So I tried that

  auto* track = step->GetTrack();
  auto* def = track->GetDefinition();
  if (def->GetParticleName() == "e-") {
    if (track->GetParentID() > 0 && track->GetCreatorProcess()) {
        G4String creator = track->GetCreatorProcess()->GetProcessName();
        if (creator == "compt" || creator == "phot" || creator == "conv") {
            fEventAction->AddStep(pos.x(), pos.y(), pos.z(), edep);
            fEventAction->AddE(edep);
        }
    }
}
 

which means only secondary electron generated by gamma could be recorded. But the total energy is larger than the gamma spectrum of Tl-208 (2.6 MeV).

So my questions are:

Is my logic is correct? If it’s true, why the values larger than 2.6 MeV were observed in my spectrum?

How could I select specified decay model (such as only gamma decay)? Is there any example?

Besides I also print some informations.

Nb of generated particles:

          F19:      81  Emean =  50.62 eV 	( 2.217 eV  --> 327.1 eV )

         Ge70:      51  Emean =  11.62 eV 	( 795.3 meV --> 62.9 eV )

         Ge72:      51  Emean =   12.6 eV 	( 793.6 meV --> 85.05 eV )

         Ge73:      14  Emean =  15.19 eV 	( 1.217 eV  --> 102.4 eV )

         Ge74:      83  Emean =  11.37 eV 	( 624.6 meV --> 72.29 eV )

         Ge76:      11  Emean =  9.642 eV 	( 569 meV --> 42.44 eV )

           e+:     310  Emean =  781.2 keV	( 55.16 keV --> 1.573 MeV)

           e-:   88942  Emean =  248.7 keV	( 899.8 meV --> 2.604 MeV)

        gamma:   35630  Emean =  965.9 keV	( 1.242 keV --> 2.615 MeV)

Geant4 Version: 11.2
Operating System: macosxarm64
Compiler/Version: clang-1500.3.9.4
CMake Version: 3.9


I guess you got 2.6 MeV from the line of created e-. This is the initial kinetic energy of individual electrons.

It seems you sum up edep over the whole event before to plot.

Yes, I want to record the total energy deposition for an event.

Here, a printout of example rdecay01 which shows why the total energy deposit can exceed 2.6 MeV

dmleo.mac.txt (250 Bytes)

dmleo.out.txt (12.2 KB)

Tl208 decay scheme (source) goes to multiple excited states of Pb208, with small but non-negative probabilities of gamma cascades. These will pass your filters.