Fitting a TGraph2D

Dear all,

I am using a “line3Dfit.C” macro to perform 3D linear fits (see the link below). I guess the variable which gives the goodness of the fit is MinFcnValue(), right? What is the exact meaning of this? And how proceed to get the chi2 instead?

Cheers,

Diego

https://root.cern.ch/root/html/tutorials/fit/line3Dfit.C.html

A better link to this example is here:
https://root.cern/doc/master/line3Dfit_8C.html

Hi Diego,

After

   const ROOT::Fit::FitResult & result = fitter.Result();

you can check with the fit result, see https://root.cern/doc/master/classROOT_1_1Fit_1_1FitResult.html#a7c9f32548341b056c97dbcc767dcd5e2

Cheers, Axel.

Dear Couet and Axel,

Thanks for answering. I already tried to replace “result.MinFcnValue()” by “result.Chi2()” in my code and I get always “-1” as result. This is the problem.

Cheers,

Diego

@moneta does that mean the fit did not converge?

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