Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.graphics.apps.gnuplot > #265

Re: Fitting: How does gnuplot calculate the covariance matrix?

From Ingo Thies <ingo.thies@gmx.de>
Newsgroups comp.graphics.apps.gnuplot
Subject Re: Fitting: How does gnuplot calculate the covariance matrix?
Date 2011-04-15 13:47 +0200
Message-ID <90qpj4FrbmU1@mid.individual.net> (permalink)
References <9088euFi3iU1@mid.individual.net> <908n9pF2jaU1@mid.individual.net> <90e7s7F9faU1@mid.dfncis.de>

Show all headers | View raw


On 10.04.2011 19:31, Hans-Bernhard Bröker wrote:

>> a = 9.482095E-01 -/+-1.947044E-01, 1.947043E-01
>> b = 4.270960E-01 -/+-8.327496E-02, 8.327495E-02
> 
> Those errors are _way_ too big.  Do yourself a favour and plot your data
> along with the model, using parameters modified by those errors:

I have now found the reason for the large errorbars. I simply had used
the wron degree of freedom for calculating the 68.3% probability ("1
sigma") contours in the (a,b) space. It should be 2 (2 params) for the
contours, and even only 1 for a single contouf (cf Numerical Recipes
chapter 15.6), but I used ndata-2, which is only valid for the
goodness-of-fit estimate. Now the errors are about the same as gnuplot's
given a good fit (i.e. \chi^2 \approx ndata-2).

Gnuplot seems to assume a good fit always, so the a-b errors do not vary
if all sigma(y_i) are scaled by the same factor. Maybe this is a
reasonable assumption since otherwise the whole fit is in question.

I hope I could repair a bit of the confusion I caused with this thread ;-)

-- 
Gruß,
      Ingo

Back to comp.graphics.apps.gnuplot | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Fitting: How does gnuplot calculate the covariance matrix? Ingo Thies <ingo.thies@gmx.de> - 2011-04-08 13:05 +0200
  Re: Fitting: How does gnuplot calculate the covariance matrix? Ingo Thies <ingo.thies@gmx.de> - 2011-04-08 17:18 +0200
    Re: Fitting: How does gnuplot calculate the covariance matrix? Hans-Bernhard Bröker <HBBroeker@t-online.de> - 2011-04-10 19:31 +0200
      Re: Fitting: How does gnuplot calculate the covariance matrix? Charles Allen <ca137tmp@earthlink.net> - 2011-04-10 20:14 -0500
        Re: Fitting: How does gnuplot calculate the covariance matrix? Ingo Thies <ingo.thies@gmx.de> - 2011-04-14 15:41 +0200
      Re: Fitting: How does gnuplot calculate the covariance matrix? Ingo Thies <ingo.thies@gmx.de> - 2011-04-11 21:42 +0200
        Re: Fitting: How does gnuplot calculate the covariance matrix? Hans-Bernhard Bröker <HBBroeker@t-online.de> - 2011-04-11 23:27 +0200
          Re: Fitting: How does gnuplot calculate the covariance matrix? Ingo Thies <ingo.thies@gmx.de> - 2011-04-12 11:28 +0200
            Re: Fitting: How does gnuplot calculate the covariance matrix? Hans-Bernhard Bröker <HBBroeker@t-online.de> - 2011-04-16 00:03 +0200
              Re: Fitting: How does gnuplot calculate the covariance matrix? Ingo Thies <ingo.thies@gmx.de> - 2011-04-16 18:06 +0200
      Re: Fitting: How does gnuplot calculate the covariance matrix? Ingo Thies <ingo.thies@gmx.de> - 2011-04-14 15:07 +0200
      Re: Fitting: How does gnuplot calculate the covariance matrix? Ingo Thies <ingo.thies@gmx.de> - 2011-04-15 13:47 +0200
  Re: Fitting: How does gnuplot calculate the covariance matrix? Hans-Bernhard Bröker <HBBroeker@t-online.de> - 2011-04-10 19:04 +0200
    Re: Fitting: How does gnuplot calculate the covariance matrix? Ingo Thies <ingo.thies@gmx.de> - 2011-04-11 22:13 +0200

csiph-web