Hello, is there any features to concatenate two RDataframe (as pandas concatenate)?
This is my problem. I have a TTree with a branch called weight
. I have to use this variables, but after dividing it by the sum of all the weight
in the TTree. This is easily doable. The problem is that I have to use several input TTrees (from different files) and for each of them I have to consider the value of weight
divided by the sum of the weight, where the sum of the weights is computed for each file (actually a bit more complicated since it is for group of files).
My workflow with pandas (via uproot) is:
- load all the TTrees in different dataframes
- for each TTree compute the sum of weights
- add a new column, equal to the weight column divided by the sum
- concatenate all the dataframes