10 if (
reject && x[0] > 2.5 && x[0] < 3.5) {
14 return par[0] + par[1]*x[0];
19 TF1 *
f1 =
new TF1(
"f1",
"[0] +[1]*x +gaus(2)",0,5);
22 TH1F *
h =
new TH1F(
"h",
"background + signal",100,0,5);
34 gROOT->GetListOfFunctions()->Remove(fleft);
38 gROOT->GetListOfFunctions()->Remove(fright);
TList * GetListOfFunctions() const
virtual void SetParameters(const Double_t *params)
1-D histogram with a float per channel (see TH1 documentation)}
virtual void FillRandom(const char *fname, Int_t ntimes=5000)
Fill histogram following distribution in function fname.
virtual void Draw(Option_t *option="")
Draw this histogram with options.
static void RejectPoint(Bool_t reject=kTRUE)
Static function to set the global flag to reject points the fgRejectPoint global flag is tested by al...
Double_t fline(Double_t *x, Double_t *par)
virtual Double_t * GetParameters() const
virtual void Add(TObject *obj)
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.