23 auto list =
new TList();
26 for (
Int_t bin = 0; bin < nbins; bin++) {
30 g->SetMarkerStyle(25);
38 auto g =
dynamic_cast<TGraph *
>(list->At(bin));
48 auto histo =
dynamic_cast<TH1F *
>(obj);
59 TList *list =
nullptr;
84 auto dir =
gROOT->GetTutorialDir();
85 dir.Append(
"/hsimple.C");
86 dir.ReplaceAll(
"/./",
"/");
89 auto file = (
TFile *)
gROOT->ProcessLineFast(
"hsimple(1)");
94 file->GetObject(
"ntuple",
ntuple);
97 const char *cut =
"pz > 3.0";
100 Canvas1->HighlightConnect(
"Highlight3(TVirtualPad*,TObject*,Int_t,Int_t)");
107 ntuple->Draw(
"pz>>histo1(100, 2.0, 12.0)", cut);
109 auto info1 =
new TText(7.0,
histo1->GetMaximum() * 0.6,
"please move the mouse over the frame");
116 ntuple->Draw(
"(px*py*pz)>>histo2(100, -50.0, 50.0)", cut);
131 ntuple->Draw(
"px:py", cut);
136 gcommon->GetXaxis()->SetTitle(
htemp->GetXaxis()->GetTitle());
137 gcommon->GetYaxis()->SetTitle(
htemp->GetYaxis()->GetTitle());
141 ntuple->Draw(
"px:py:pz", cut,
"goff");
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void value
virtual Color_t GetLineColor() const
Return the line color.
A ROOT file is an on-disk file, usually with extension .root, that stores objects in a file-system-li...
A TGraph is an object made of two arrays X and Y with npoints each.
virtual void SetPoint(Int_t i, Double_t x, Double_t y)
Set x and y values for point number i.
1-D histogram with a float per channel (see TH1 documentation)
virtual Int_t GetNbinsX() const
virtual Bool_t IsHighlight() const
virtual Int_t FindBin(Double_t x, Double_t y=0, Double_t z=0)
Return Global bin number corresponding to x,y,z.
2-D histogram with a float per channel (see TH1 documentation)
const char * GetName() const override
Returns name of object.
A simple TTree restricted to a list of float variables only.
Mother of all ROOT objects.
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString.
Base class for several text objects.
TVirtualPad is an abstract base class for the Pad and Canvas classes.