Simple RDataFrame example in C++.
This tutorial shows a minimal example of RDataFrame. It starts without input data, generates a new column x
with random numbers, and finally draws a histogram for x
.
{
auto rdf_x = rdf.Define(
"x", [](){
return gRandom->
Rndm(); });
auto h = rdf_x.Histo1D(
"x");
}
R__EXTERN TRandom * gRandom
ROOT's RDataFrame offers a high level interface for analyses of data stored in TTree,...
virtual Double_t Rndm()
Machine independent random number generator.
- Date
- September 2021
- Author
- Enric Tejedor (CERN)
Definition in file df000_simple.C.