RDataFrame Constructor from a TChain

Hi,

We are starting to convert some our analysis tool to using RDataFrame, but without rewriting everything. We quickly ran into an issue that we are passing TChain* around to which RDataFrame does not have a constructor. Are there plans to remedy this? Any suggestions on how to construct an RDataFrame from the TChain* by getting a list of files or something along those lines in the meantime?

Thanks


ROOT Version: 6.14.04


Hi,
RDataFrame has a constructor that takes a TTree&, to which you can safely pass a TChain& as TChain inherits from TTree.

Looking forward to hear how RDF works for your usecase!
Cheers,
Enrico

Ahh, sorry I read the signature wrong and missed that we needed to dereference the pointer.

auto df = ROOT::RDataFrame(*chainPtr);

Thanks for the quick response.

1 Like

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