From f64e7a7539f474b1c2b71126d9c26037e6698ddc Mon Sep 17 00:00:00 2001 From: Danilo Piparo <danilo.piparo@cern.ch> Date: Wed, 4 Oct 2017 11:38:50 +0200 Subject: [PATCH] Formatting --- tree/treeplayer/src/TDFHistoModels.cxx | 13 +++++-------- tutorials/dataframe/tdf003_profiles.C | 8 ++++---- 2 files changed, 9 insertions(+), 12 deletions(-) diff --git a/tree/treeplayer/src/TDFHistoModels.cxx b/tree/treeplayer/src/TDFHistoModels.cxx index e2f873103d4..6a06f6b0b70 100644 --- a/tree/treeplayer/src/TDFHistoModels.cxx +++ b/tree/treeplayer/src/TDFHistoModels.cxx @@ -91,8 +91,7 @@ TH3DModel::~TH3DModel() TProfile1DModel::TProfile1DModel(const ::TProfile &h) : fName(h.GetName()), fTitle(h.GetTitle()), fNbinsX(h.GetNbinsX()), fXLow(h.GetXaxis()->GetXmin()), - fXUp(h.GetXaxis()->GetXmax()), fYLow(h.GetYmin()), fYUp(h.GetYmax()), - fOption(h.GetErrorOption()) + fXUp(h.GetXaxis()->GetXmax()), fYLow(h.GetYmin()), fYUp(h.GetYmax()), fOption(h.GetErrorOption()) { } TProfile1DModel::TProfile1DModel(const char *name, const char *title, int nbinsx, double xlow, double xup, @@ -101,10 +100,9 @@ TProfile1DModel::TProfile1DModel(const char *name, const char *title, int nbinsx { } -TProfile1DModel::TProfile1DModel(const char *name, const char *title, int nbinsx, double xlow, double xup, - double ylow, double yup, const char *option) - : fName(name), fTitle(title), fNbinsX(nbinsx), fXLow(xlow), fXUp(xup), fYLow(ylow), fYUp(yup), - fOption(option) +TProfile1DModel::TProfile1DModel(const char *name, const char *title, int nbinsx, double xlow, double xup, double ylow, + double yup, const char *option) + : fName(name), fTitle(title), fNbinsX(nbinsx), fXLow(xlow), fXUp(xup), fYLow(ylow), fYUp(yup), fOption(option) { } @@ -115,8 +113,7 @@ TProfile1DModel::~TProfile1DModel() TProfile2DModel::TProfile2DModel(const ::TProfile2D &h) : fName(h.GetName()), fTitle(h.GetTitle()), fNbinsX(h.GetNbinsX()), fXLow(h.GetXaxis()->GetXmin()), fXUp(h.GetXaxis()->GetXmax()), fNbinsY(h.GetNbinsY()), fYLow(h.GetYaxis()->GetXmin()), - fYUp(h.GetYaxis()->GetXmax()), fZLow(h.GetZmin()), fZUp(h.GetZmax()), - fOption(h.GetErrorOption()) + fYUp(h.GetYaxis()->GetXmax()), fZLow(h.GetZmin()), fZUp(h.GetZmax()), fOption(h.GetErrorOption()) { } TProfile2DModel::TProfile2DModel(const char *name, const char *title, int nbinsx, double xlow, double xup, int nbinsy, diff --git a/tutorials/dataframe/tdf003_profiles.C b/tutorials/dataframe/tdf003_profiles.C index e221adbf987..d91d8e5045c 100644 --- a/tutorials/dataframe/tdf003_profiles.C +++ b/tutorials/dataframe/tdf003_profiles.C @@ -15,10 +15,10 @@ void fill_tree(const char *treeName, const char *fileName) { ROOT::Experimental::TDataFrame d(25000); - d.Define("px", [](){return gRandom->Gaus();}) - .Define("py", [](){return gRandom->Gaus();}) - .Define("pz", [](double px, double py){return sqrt(px * px + py * py);}, {"px", "py"}) - .Snapshot(treeName, fileName); + d.Define("px", []() { return gRandom->Gaus(); }) + .Define("py", []() { return gRandom->Gaus(); }) + .Define("pz", [](double px, double py) { return sqrt(px * px + py * py); }, {"px", "py"}) + .Snapshot(treeName, fileName); } void tdf003_profiles() -- GitLab