I wanted to ask about this statement
" One another thing is that is not efficient to build RooDataHist objects with multi-variables. For example for 2 variables with n1 and n2 bins, RooFit will allocate n1 x n2 bins."
How many bins are allocated when using RooDataSet? This is important if use this approach to fit a large number of ranges, not two, as in the example, but, for example, 100?
Hi @purgenetik1, thanks for sharing the script, that looks correct to me!
The RooDataSet is like a table with one row per bin, and one column to tell which category (or “line” in your case) the bin corresponds to. The number of entries in total is therefore the sum of bin numbers, and this approach is very suitable is for fitting many categories (in fact, the ATLAS Higgs combination fits are fitting hundreds of measurement channels simultaneously using this approach!).
I also want to note the universal method of converting any histogram into a tree, which allows to skip RooDataHist fitting in favor of unbinned RooDataSet fit.
I also want to note the universal method of converting any histogram into a tree, which allows to skip RooDataHist fitting in favor of unbinned RooDataSet fit.