I have a very general question. What I would like to do is to determine the significance of a signal (e.g. resonance on top of a background in an energy dependent cross section measurement). For that purpose one usually can apply a likelihood ratio test, i.e. fit once with (H1), once without (H0) the signal component, where the test statistics is LR = -2(log LH_0 - log LH_1) and the significance is Z = sqrt(LR).

It looks like the method TGraphErrors::Fit doesn’t accept the option “L” for maximum likelihood fitting, and I’m anyways not sure whether a simple ML fit is appropriate/proper in that respect.

Is there a way to approach that problem differently, perhaps with weighted ML fit in RooFit?

Hi,
In the case of a TGraphErrors (without errors in the X coordinate), the Likelihood is the same as the least square function used for fitting when the errors are assumed to be normal distributed.
You can then compute your test statistics from the fitting with the H0 and H1 hypothesis

thanks for the clarification! But how is it in case (I forgot to mention) the errors are not normal (poisson) distributed, since the points are individual measurements where the error bars reflect multiple (systematic) error sources?

You can always uses the points to build the likelihood according to your model. In general we cannot assume a Poisson for a TGraphErrors, since we don’t have bins and therefore we don’t know how to compute the expected values for each point.
However, I think if you have multiple systematics you can often assume the errors are normal.