Pythia event generation

Hello everyone,
I generated events in Pythia, with two QCD processes. I observed my particle with spesific cuts and obtained 10 particles, i want. but now i’m trying to understand which process my particle comes from. I have to see the ratios as three K* from first process and seven K* from second process and cant use mother1() function because i need the process not particles. I also saw codeSub() function in manual, but i didnt understand usage of it. Does anybody know a function or switch for this selection? Thanks in advance.

Hello,

this seems more a Pythia question rather than a ROOT one.

Best,
Danilo