29constexpr char const *kTreeFileName =
"http://root.cern.ch/files/HiggsTauTauReduced/GluGluToHToTauTau.root";
30constexpr char const *kTreeName =
"Events";
31constexpr char const *kNTupleFileName =
"ntpl008_import.root";
43 auto importer = RNTupleImporter::Create(kTreeFileName, kTreeName, kNTupleFileName);
49 auto file = std::unique_ptr<TFile>(
TFile::Open(kNTupleFileName));
50 if (!file || file->IsZombie()) {
51 std::cerr <<
"cannot open " << kNTupleFileName << std::endl;
54 auto ntpl = std::unique_ptr<ROOT::RNTuple>(file->Get<
ROOT::RNTuple>(
"Events"));
55 auto reader = RNTupleReader::Open(*ntpl);
59 df.Histo1D({
"Jet_pt",
"Jet_pt", 100, 0, 0},
"Jet_pt")->DrawCopy();
R__EXTERN TSystem * gSystem
Converts a TTree into an RNTuple.
An RNTuple that is used to read data from storage.
ROOT's RDataFrame offers a modern, high-level interface for analysis of data stored in TTree ,...
Representation of an RNTuple data set in a ROOT file.
static TFile * Open(const char *name, Option_t *option="", const char *ftitle="", Int_t compress=ROOT::RCompressionSetting::EDefaults::kUseCompiledDefault, Int_t netopt=0)
Create / open a file.
virtual int Unlink(const char *name)
Unlink, i.e.
void EnableImplicitMT(UInt_t numthreads=0)
Enable ROOT's implicit multi-threading for all objects and methods that provide an internal paralleli...