45sig1frac =
ROOT.RooRealVar(
"sig1frac",
"fraction of component 1 in signal", 0.8, 0.0, 1.0)
52bkgfrac =
ROOT.RooRealVar(
"bkgfrac",
"fraction of background", 0.5, 0.0, 1.0)
65xframe =
x.frame(Title=
"Example of composite pdf=(sig1+sig2)+bkg")
73model.plotOn(xframe, Components={bkg, sig2}, LineStyle=
":")
85model2 =
ROOT.RooAddPdf(
"model",
"g1+g2+a", [bkg, sig1, sig2], [bkgfrac, sig1frac],
True)
97model2.plotOn(xframe, Components={bkg, sig2}, LineColor=
"r", LineStyle=
"--")
101c =
ROOT.TCanvas(
"rf201_composite",
"rf201_composite", 600, 600)
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.