combinedFit.C chi2->likelihood

Dear All,

There exist this very usefull tutorial (combinedFit.C )
on how to fit 2 historgrams with 2 functions which have some common parameters.

My problem is that I need likelihood fit not the chi2 one.
Does somebody could summarise what are the minimal changes to be done in combinedFit.C code to go from chi2 fit to the likelihood one?

Thanks in advance for help!

ROOT Version: Not Provided
Platform: Not Provided
Compiler: Not Provided


You could use the likelihood by just replacing the ROOT::Fit::Chi2Function used to create the chi2 with the ROOT::Fit::PoissonLLFunction (line 101 and 102 of combinedFiit.C)

I attach as reference the modified macro


combinedFit.C (4.1 KB)

1 Like

Thanks a lot for help!


This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.