Uploaded image for project: 'ROOT'
  1. ROOT
  2. ROOT-10367

RooFormulaVar with categories crash when plotted

    XMLWordPrintable

    Details

      Description

      void testFormulaCrash()
      {
          RooRealVar x("x", "x", 0, 1);
          RooCategory c("c", "c");
          c.defineType("p", 1);
          c.defineType("n", -1);
          c.setIndex(1);
          
          RooFormulaVar f("test", "x*c", RooArgList(x,c));
          
          // works
          cout << f.getVal() << endl;
          
          auto frame = x.frame();
          // crashes
          f.plotOn(frame);
          
          frame->Draw();
      }
      

        Attachments

          Activity

            People

            • Assignee:
              shageboe Stephan Hageboeck
              Reporter:
              shageboe Stephan Hageboeck
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: