Hi,
So I am fitting a data set with a pdf sum of multiple things. to do this I use the following format
RooDataHist data("data","data",x,hData);
RooAddPdf sum("sum","sum", RooArgSet(Pdf1,Pdf2,Pdf3), RooArgSet(Param1,Param2,Param3));
sum.fitTo(data,extended());
data.plotOn(frame);
sum.plotOn(frame);
I can get a reasonable value through
frame->chiSquare();
and
frame->chiSquare(n);
but if I try to specify which things to compare
frame->chiSquare(“sum”,“data”,n);
it just returns -1, what am I doing wrong, any ideas?
George