Read root files from txt file and analyze

Hi,

I have a .txt file containing the path and name of a large number of root files. The files are located in a remote location. The root files are n-tuple (NanoAOD type). Now I want to write a code to do my analysis. So, basically, I want to create a code that will read the root files one by one from the .txt file, and then it will do the analysis. Could you please provide an example of the same?

Thanks & Regards,
Soumyadip

Try to contact the authors of your (NanoAOD) ROOT files. They should have some examples showing how to use them.

Is there any general example available?

grep -r -i NanoAOD ${ROOTSYS}/t[eu]*

Hi @Soumyadip ,
see e.g. ROOT: tutorials/dataframe/df102_NanoAODDimuonAnalysis.C File Reference (and the RDataFrame documentation at ROOT: ROOT::RDataFrame Class Reference ).

Cheers,
Enrico

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.