[ADMB Users] "Hessian does not appear to be positive definite"

dave fournier davef at otter-rsch.com
Thu Apr 23 13:10:56 PDT 2009


Sylvain Bonhommeau wrote:

What you are coming up against here are the limits of estimability.
If you remove the  std dev from the model and just fit the least squares
and then
calculate the mean-squared residuals you will get 0.000821022 so the model
fits the data almost perfectly. the fact that they are not the values
you used
to generate the data simply reflects the fact that there is not a lot of
information in the data
i.e. thee are different combinations of the model parameters which fit
the model (almost) equally well.

          Dave

> Hi,
>
> I want to test the ability of my procedure to estimate parameters so I
> simulated data with known parameters. As you mentioned previously,
> when there is no errors, it is not possible to get the standard
> deviation. However in the .par file, the value of parameters are
> almost perfect. The problem is when I add a small noise to my
> simulated data, i.e. multiplying by a random variable normally
> distributed with mean=1 and sd=0.01, the estimated parameters are not
> the one I chose...
>
> I attach the .tpl, .pin and the two .dat file (without and with error)
> as well as the R script to simulate the data.
>
> (this is a simplified version of the model I sent you before)
>
>
> Thanks for your help,
>
> Sylvain
>
>
>
> 2009/4/9 dave fournier <otter at otter-rsch.com
> <mailto:otter at otter-rsch.com>>
>
>     I think we should keep this on the list as these are issures whihc may
>     interest other users.  If the data are perfect then  the residuals are
>     amost zero and the estimate for the standard deviation is almost
>     zero so
>     you get a
>
>                 0/0
>
>     situation. very unlikely that this will occur with real data.
>
>     If you are moving on to random effects you should first civilize the
>     model a bit.  In somethng like
>
>        exp( a(1) + a(2)*v + a(3)*v^2 )
>
>     you should at least center v as in
>
>              w = v -mean(v)
>
>              mfexp( a(1) + a(2)*w + a(3)*w^2 )
>
>     The use of mfexp is to avoid overflow.
>
>     also you might fit a(1) first as in
>
>           PARAMETER_SECTION
>
>               init_number a1                    // fit in phase 1
>               init_vector a(2,3,2)              .. fit in phase 2
>
>
>
>         mfexp( a1 + a(2)*w + a(3)*w^2 )
>
>
>
>
>
>
>     Thanks guys. It runs well now with both methods you mentioned. I seems
>     like it is not good to have perfect data! I gonna try the random
>     effect
>     module now...
>
>     Cheers,
>
>     Sylvain
>
>     2009/4/9 Mark Maunder <mmaunder at iattc.org <mailto:mmaunder at iattc.org>>
>
>        I see that Dave found that it was related to having no error in the
>     simulated data. I guess if you fixed the standard deviation (use a
>     negative phase) it might work without adding error.
>
>
>
>        Mark
>
>
>
>        From: Sylvain Bonhommeau [mailto:sylvain.bonhommeau at gmail.com
>     <mailto:sylvain.bonhommeau at gmail.com>]
>        Sent: Thursday, April 09, 2009 8:39 AM
>        To: Mark Maunder
>        Subject: Re: [ADMB Users] "Hessian does not appear to be positive
>     definite"
>
>
>
>        Hi Mark,
>
>        Thanks for your answer.
>        I simulated the data with R (code below). There is no error
>     added to
>     data for now but that is the aim of today. I specified a pin file and
>     the initial conditions are not (but close to) the "known" parameters.
>
>        Thanks,
>
>        Sylvain
>
>
>     --
>     David A. Fournier
>     P.O. Box 2040,
>     Sidney, B.C. V8l 3S3
>     Canada
>     Phone/FAX 250-655-3364
>     http://otter-rsch.com
>     _______________________________________________
>     Users mailing list
>     Users at admb-project.org <mailto:Users at admb-project.org>
>     http://lists.admb-project.org/mailman/listinfo/users
>
>


-- 
David A. Fournier
P.O. Box 2040, 
Sidney, B.C. V8l 3S3
Canada
Phone/FAX 250-655-3364
http://otter-rsch.com




More information about the Users mailing list