I was looking into saving the deposited energy (and maybe more) for each particle in a run of several thousands of them, but also the averaged one.All of it should be saved in the form of histograms in root format. I wanted this output written as different files but while adapting my previous code (based on TestEm11 example which provides mean histograms), I figured out that analysis manager can only have 1 instance. I initially wanted to have one instance dedicated to the run level of information (id est average) and one instance for each event, that would be opening and closing files.
I know that by saving all information I require in ntuples then post-process it into different files that would work but ntuples are heavier than histograms and not my first choice.
Is there any easy way to have 2 files opened at the same time? I know that Multithreading opens several files then merge them…