I’m quite new to ROOT and would like some advice on how to think about reading data from a file into a TTree, including some computations in the process. I have say 40 text files each with 16 columns of numbers. From the numbers in each column I want to calculate 3 quantities. This makes a 3*16-variable space, in which each of the 40 files will generate one data point. In the end I thus want a TTree with 48 leaves for each of the variables, with 40 entries. (Finally, I want to make a statistical analysis on these, a Principal Component Analysis, but that’s for later).
How would you go about to do this? I would just like to hear how someone experienced would reason on a problem like this.
At the moment I’m first reading in the data to a tree to calculate the three quantities, and then once they’re calculated written to a new tree. I’m not sure this is a very clever way though.