26 return par[0] + par[1]*
x[0] + par[2]*
x[0]*
x[0];
47 double data[nBins] = { 6, 1,10,12, 6,13,23,22,15,21,
48 23,26,36,25,27,35,40,44,66,81,
49 75,57,48,45,46,41,35,36,53,32,
50 40,37,38,31,36,44,42,37,32,32,
51 43,44,35,33,33,39,29,41,32,44,
52 26,39,29,35,32,21,21,15,25,15};
55 c1->SetFrameFillColor(41);
59 "Lorentzian Peak on Quadratic Background",60,0,3);
78 histo->
Fit(
"fitFcn",
"0");
84 histo->
Fit(
"fitFcn",
"V+",
"ep");
106 legend->SetTextSize(0.04);
107 legend->AddEntry(histo,
"Data",
"lpe");
110 legend->AddEntry(fitFcn,
"Global Fit",
"l");
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 data
virtual void SetLineWidth(Width_t lwidth)
Set the line width.
virtual void SetLineColor(Color_t lcolor)
Set the line color.
virtual void SetMarkerStyle(Style_t mstyle=1)
Set the marker style.
virtual void SetMarkerSize(Size_t msize=1)
Set the marker size.
virtual void SetNpx(Int_t npx=100)
Set the number of points used to draw the function.
virtual Double_t * GetParameters() const
virtual void SetParameters(const Double_t *params)
virtual void SetParameter(Int_t param, Double_t value)
1-D histogram with a float per channel (see TH1 documentation)
virtual TFitResultPtr Fit(const char *formula, Option_t *option="", Option_t *goption="", Double_t xmin=0, Double_t xmax=0)
Fit histogram with function fname.
virtual void SetBinContent(Int_t bin, Double_t content)
Set bin content see convention for numbering bins in TH1::GetBin In case the bin number is greater th...
virtual void SetStats(Bool_t stats=kTRUE)
Set statistics option on/off.
This class displays a legend box (TPaveText) containing several legend entries.
Short_t Max(Short_t a, Short_t b)
Returns the largest of a and b.