18tagCat = ROOT.RooCategory(
"tagCat",
"Tagging category")
19tagCat.defineType(
"Lepton")
20tagCat.defineType(
"Kaon")
21tagCat.defineType(
"NetTagger-1")
22tagCat.defineType(
"NetTagger-2")
26b0flav = ROOT.RooCategory(
"b0flav",
"B0 flavour eigenstate", {
"B0": -1,
"B0bar": 1})
30x = ROOT.RooRealVar(
"x",
"x", 0, 10)
31p = ROOT.RooPolynomial(
"p",
"p", x)
32data = p.generate({x, b0flav, tagCat}, 10000)
40tcatType = ROOT.RooMappedCategory(
"tcatType",
"tagCat type", tagCat,
"Cut based")
43tcatType.map(
"Lepton",
"Cut based")
44tcatType.map(
"Kaon",
"Cut based")
47tcatType.map(
"NetTagger*",
"Neural Network")
50mtable = data.table(tcatType)
58b0Xtcat = ROOT.RooSuperCategory(
"b0Xtcat",
"b0flav X tagCat", {b0flav, tagCat})
61stable = data.table(b0Xtcat)
65b0Xtcat.setLabel(
"{B0bar;Lepton}")
69b0Xttype = ROOT.RooMultiCategory(
"b0Xttype",
"b0flav X tagType", {b0flav, tcatType})
72xtable = data.table(b0Xttype)