28void rs602_HLFactoryCombinationexample()
31 TString card_name(
"HLFavtoryCombinationexample.rs");
32 ofstream ofile(card_name);
33 ofile <<
"// The simplest card for combination\n\n"
34 <<
"gauss1 = Gaussian(x[0,100],mean1[50,0,100],4);\n"
35 <<
"flat1 = Polynomial(x,0);\n"
36 <<
"sb_model1 = SUM(nsig1[120,0,300]*gauss1 , nbkg1[100,0,1000]*flat1);\n"
37 <<
"gauss2 = Gaussian(x,mean2[80,0,100],5);\n"
38 <<
"flat2 = Polynomial(x,0);\n"
39 <<
"sb_model2 = SUM(nsig2[90,0,400]*gauss2 , nbkg2[80,0,1000]*flat2);\n";
43 HLFactory hlf(
"HLFavtoryCombinationexample", card_name,
false);
45 hlf.AddChannel(
"model1",
"sb_model1",
"flat1");
46 hlf.AddChannel(
"model2",
"sb_model2",
"flat2");
47 auto pdf = hlf.GetTotSigBkgPdf();
48 auto thecat = hlf.GetTotCategory();
49 auto x =
static_cast<RooRealVar *
>(hlf.GetWs()->arg(
"x"));
57 auto xframe =
x->frame();
66 gROOT->SetStyle(
"Plain");
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void data
RooArgSet is a container object that can hold multiple RooAbsArg objects.
Variable that can be changed from the outside.
HLFactory is an High Level model Factory allows you to describe your models in a configuration file (...
RooCmdArg Extended(bool flag=true)
RooCmdArg ProjWData(const RooAbsData &projData, bool binData=false)
RooCmdArg Slice(const RooArgSet &sliceSet)
The namespace RooFit contains mostly switches that change the behaviour of functions of PDFs (or othe...
Namespace for the RooStats classes.