Stanislav Vinogradov wrote:
I had used the gnuplot as well as the GSL facilities for
fitting my experimental data by power law y~ b*x^a.
When I approximate data by linear algorithm (in logarithmic
variables) both gnuplot and GSL give the same results.
But if data had been approximated directly by power law
and nonlinear fitting algorithm, the GSL fit give the same
results, as gnuplot, but with sufficiently greater error
estimates. The heart is that in GSL, against to gnuplot,
for poor fit (when the chi-squared per degree of freedom
(dof) is greater then 1) errors obtained from the covariance
matrix are scaled by factor sqrt(chi^2/dof)
So, what approach is more correct?
Hello,
GSL only computes the covariance matrix in gsl_multifit_covar. It's up
to the user whether they want to calculate the error with or without a
scaling factor GSL_MAX_DBL(1, chi / sqrt(dof)).
The example program uses a scaling factor of sqrt(chisq / sqrt(dof)) but
it's just an example. Personally I would recommend that choice, along
with quoting the chisq/dof.
--
best regards,
Brian Gough
(GSL Maintainer)
Network Theory Ltd,
Publishing the GSL Manual - http://www.network-theory.co.uk/gsl/manual/
_______________________________________________
Help-gsl mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-gsl