Logo ROOT  
Reference Guide
rf205_compplot Namespace Reference

Variables

 a0 = ROOT.RooRealVar("a0", "a0", 0.5, 0.0, 1.0)
 a1 = ROOT.RooRealVar("a1", "a1", -0.2, 0.0, 1.0)
 alpha = ROOT.RooRealVar("alpha", "alpha", -1)
 bkg = ROOT.RooAddPdf("bkg", "Total background", [bkg1, bkg2], [bkg1frac])
 bkg1 = ROOT.RooChebychev("bkg1", "Background 1", x, [a0, a1])
 bkg1frac = ROOT.RooRealVar("bkg1frac", "fraction of component 1 in background", 0.8, 0.0, 1.0)
 bkg2 = ROOT.RooExponential("bkg2", "Background 2", x, alpha)
 bkgfrac = ROOT.RooRealVar("bkgfrac", "fraction of background", 0.5, 0.0, 1.0)
 c = ROOT.TCanvas("rf205_compplot", "rf205_compplot", 800, 400)
 Components
 data = model.generate({x}, 1000)
 Invisible
 LineColor
 LineStyle
 mean = ROOT.RooRealVar("mean", "mean of gaussians", 5)
 model = ROOT.RooAddPdf("model", "g1+g2+a", [bkg, sig], [bkgfrac])
dict ras_bkg = {bkg}
dict ras_bkg2 = {bkg2}
dict ras_bkg_sig2 = {bkg, sig2}
 sig = ROOT.RooAddPdf("sig", "Signal", [sig1, sig2], [sig1frac])
 sig1 = ROOT.RooGaussian("sig1", "Signal component 1", x, mean, sigma1)
 sig1frac = ROOT.RooRealVar("sig1frac", "fraction of component 1 in signal", 0.8, 0.0, 1.0)
 sig2 = ROOT.RooGaussian("sig2", "Signal component 2", x, mean, sigma2)
 sigma1 = ROOT.RooRealVar("sigma1", "width of gaussians", 0.5)
 sigma2 = ROOT.RooRealVar("sigma2", "width of gaussians", 1)
 True
 x = ROOT.RooRealVar("x", "x", 0, 10)
 xframe = x.frame(Title="Component plotting of pdf=(sig1+sig2)+(bkg1+bkg2)")
 xframe2 = xframe.Clone("xframe2")

Variable Documentation

◆ a0

rf205_compplot.a0 = ROOT.RooRealVar("a0", "a0", 0.5, 0.0, 1.0)

Definition at line 34 of file rf205_compplot.py.

◆ a1

rf205_compplot.a1 = ROOT.RooRealVar("a1", "a1", -0.2, 0.0, 1.0)

Definition at line 35 of file rf205_compplot.py.

◆ alpha

rf205_compplot.alpha = ROOT.RooRealVar("alpha", "alpha", -1)

Definition at line 39 of file rf205_compplot.py.

◆ bkg

rf205_compplot.bkg = ROOT.RooAddPdf("bkg", "Total background", [bkg1, bkg2], [bkg1frac])

Definition at line 44 of file rf205_compplot.py.

◆ bkg1

rf205_compplot.bkg1 = ROOT.RooChebychev("bkg1", "Background 1", x, [a0, a1])

Definition at line 36 of file rf205_compplot.py.

◆ bkg1frac

rf205_compplot.bkg1frac = ROOT.RooRealVar("bkg1frac", "fraction of component 1 in background", 0.8, 0.0, 1.0)

Definition at line 43 of file rf205_compplot.py.

◆ bkg2

rf205_compplot.bkg2 = ROOT.RooExponential("bkg2", "Background 2", x, alpha)

Definition at line 40 of file rf205_compplot.py.

◆ bkgfrac

rf205_compplot.bkgfrac = ROOT.RooRealVar("bkgfrac", "fraction of background", 0.5, 0.0, 1.0)

Definition at line 47 of file rf205_compplot.py.

◆ c

rf205_compplot.c = ROOT.TCanvas("rf205_compplot", "rf205_compplot", 800, 400)

Definition at line 99 of file rf205_compplot.py.

◆ Components

rf205_compplot.Components

Definition at line 69 of file rf205_compplot.py.

◆ data

rf205_compplot.data = model.generate({x}, 1000)

Definition at line 54 of file rf205_compplot.py.

◆ Invisible

rf205_compplot.Invisible

Definition at line 96 of file rf205_compplot.py.

◆ LineColor

rf205_compplot.LineColor

Definition at line 69 of file rf205_compplot.py.

◆ LineStyle

rf205_compplot.LineStyle

Definition at line 73 of file rf205_compplot.py.

◆ mean

rf205_compplot.mean = ROOT.RooRealVar("mean", "mean of gaussians", 5)

Definition at line 23 of file rf205_compplot.py.

◆ model

rf205_compplot.model = ROOT.RooAddPdf("model", "g1+g2+a", [bkg, sig], [bkgfrac])

Definition at line 48 of file rf205_compplot.py.

◆ ras_bkg

rf205_compplot.ras_bkg = {bkg}

Definition at line 68 of file rf205_compplot.py.

◆ ras_bkg2

rf205_compplot.ras_bkg2 = {bkg2}

Definition at line 72 of file rf205_compplot.py.

◆ ras_bkg_sig2

rf205_compplot.ras_bkg_sig2 = {bkg, sig2}

Definition at line 78 of file rf205_compplot.py.

◆ sig

rf205_compplot.sig = ROOT.RooAddPdf("sig", "Signal", [sig1, sig2], [sig1frac])

Definition at line 31 of file rf205_compplot.py.

◆ sig1

rf205_compplot.sig1 = ROOT.RooGaussian("sig1", "Signal component 1", x, mean, sigma1)

Definition at line 26 of file rf205_compplot.py.

◆ sig1frac

rf205_compplot.sig1frac = ROOT.RooRealVar("sig1frac", "fraction of component 1 in signal", 0.8, 0.0, 1.0)

Definition at line 30 of file rf205_compplot.py.

◆ sig2

rf205_compplot.sig2 = ROOT.RooGaussian("sig2", "Signal component 2", x, mean, sigma2)

Definition at line 27 of file rf205_compplot.py.

◆ sigma1

rf205_compplot.sigma1 = ROOT.RooRealVar("sigma1", "width of gaussians", 0.5)

Definition at line 24 of file rf205_compplot.py.

◆ sigma2

rf205_compplot.sigma2 = ROOT.RooRealVar("sigma2", "width of gaussians", 1)

Definition at line 25 of file rf205_compplot.py.

◆ True

rf205_compplot.True

Definition at line 96 of file rf205_compplot.py.

◆ x

rf205_compplot.x = ROOT.RooRealVar("x", "x", 0, 10)

Definition at line 19 of file rf205_compplot.py.

◆ xframe

rf205_compplot.xframe = x.frame(Title="Component plotting of pdf=(sig1+sig2)+(bkg1+bkg2)")

Definition at line 57 of file rf205_compplot.py.

◆ xframe2

rf205_compplot.xframe2 = xframe.Clone("xframe2")

Definition at line 62 of file rf205_compplot.py.