24m = ROOT.RooRealVar(
"m",
"m", 5.20, 5.30)
27m0 = ROOT.RooRealVar(
"m0",
"m0", 5.291, 5.20, 5.30)
28k = ROOT.RooRealVar(
"k",
"k", -30, -50, -10)
31argus = ROOT.RooArgusBG(
"argus",
"argus", m, m0, k)
34data = argus.generate({m}, 1000)
39frame1 = m.frame(Bins=40, Title=
"Argus model and data")
56argus.fitTo(data, PrintEvalErrors=10)
70argus.fitTo(data, PrintEvalErrors=0, EvalErrorWall=
False)
76nll = argus.createNLL(data)
83frame2 = m0.frame(Range=(5.288, 5.293), Title=
"-log(L) scan vs m0, regions masked")
84nll.plotOn(frame2, ShiftToZero=
True, PrintEvalErrors=-1, EvalErrorValue=(nll.getVal() + 10), LineColor=
"r")
88c = ROOT.TCanvas(
"rf606_nllerrorhandling",
"rf606_nllerrorhandling", 1200, 400)
91ROOT.gPad.SetLeftMargin(0.15)
92frame1.GetYaxis().SetTitleOffset(1.4)
95ROOT.gPad.SetLeftMargin(0.15)
96frame2.GetYaxis().SetTitleOffset(1.4)
99c.SaveAs(
"rf606_nllerrorhandling.png")