Fitting MC fractions to data


I have 2 MC histos, mc1 and mc2, and one data histogram hdata. I want to obtain the fractions of mc1 and mc2 in data. I tried to use TFractionFitter, but the problem is that it uses by default Poisson errors. My histograms contain number of events which are obtain by fitting an invariant mass, hence their errors are not allways Poisson.

I suppose it is possible to fit mc1 and mc2 to data using TMinuit. Does anybody have an example how to do it? Or a suggestion, which is the best solution to use in this case?

Thank you,
Angela. :question:

Have a look at tutorial $ROOTSYS/fit/fithist.C. Add your second histogram to the “ftotal” function.