|
From: <pl...@pi...> - 2011-10-11 15:41:26
|
Hi,
I have hit this in a couple of ways recently in cases where it seemed it
should succeed.
The fit is basically making to a convergence , printing all the fitted
values , stats , the lot but then failing. I am wondering if it is still
necessary to it to do the invert RtR since it has done all I asked.
resultant parameter values
a0 = 384.634
b0 = 4850.85
c0 = 1e-30
pk0 = 9.10484
After 11 iterations the fit converged.
final sum of squares of residuals : 304.992
rel. change during last iteration : -1.04716e-06
degrees of freedom (FIT_NDF) : 197
rms of residuals (FIT_STDFIT) = sqrt(WSSR/ndf) : 1.24426
variance of residuals (reduced chisquare) = WSSR/ndf : 1.54818
Singular matrix in Invert_RtR
In this case I had started with data where no extra offset was needed ,
ie c0=0 was correct before running fit.
I had a similar occurrence where another via param was at its final
value and I got a singularity. If I deliberately initialised it to be a
bit off, fit put it back where it was to start with without failing.
Is it correct for the method to succeed but fail :?
Thanks.
|
|
From: <pl...@pi...> - 2011-10-11 18:20:02
|
On 10/11/11 19:44, Hans-Bernhard Bröker wrote: > On 11.10.2011 14:04, pl...@pi... wrote: > >> The fit is basically making to a convergence > > No, it's not. It's making it to failure. > >> necessary to it to do the invert RtR > > Yes. > >> since it has done all I asked. > > No, it hasn't. It may have done all you believe you need, but not all > you actually asked for. What has not been done if it has already found the result and output that it has found a convergence? I'm not saying you're wrong but it would be helpful if you said what I am missing rather than suggesting there is something more but not saying what it is . I asked for a regression fit. I got one , I got convergence (apparently according to fit) I got the results , I got the stats. I got more that I asked for. What do you think I "actually asked for"? You love being smart , being explicit would be more help. > >> In this case I had started with data where no extra offset was needed , >> ie c0=0 was correct before running fit. > > Then you _shouldn't_ have told fit to modify it. I was expecting it to be slightly different from zero but close to that value. That made it a logical starting point . If I knew it was exactly zero , clearly I would not have added it as a via parameter. I may not quite as smart as HBB but I'm not a complete cretin. > > A parameter value of zero is particularly bad in that case. No fit > parameter may be zero. _wrong_ The following works. I frequently set zero as a starting value if if makes sense. base=basedrift=0 if (use_baseline) fit baseline(x) datafile using 1:4 via base,basedrift > > As it is, you pretty much explicitly asked for 'fit' to fail. No wonder > it did. If that were the case , I seem not to have come across that rather essential point it in the doc. Since you are wrong that may explain the absence of such information. Gruss. |
|
From: Karl-Friedrich R. <mai...@gm...> - 2011-10-12 21:14:15
|
On 20:59, pl...@pi... wrote: > On 10/11/11 19:44, Hans-Bernhard Bröker wrote: >> On 11.10.2011 14:04, pl...@pi... wrote: >> A parameter value of zero is particularly bad in that case. No fit >> parameter may be zero. > _wrong_ > > The following works. I frequently set zero as a starting value if if > makes sense. > > baseºsedrift=0 > if (use_baseline) fit baseline(x) datafile using 1:4 via > base,basedrift > >> >> As it is, you pretty much explicitly asked for 'fit' to fail. No >> wonder >> it did. > > If that were the case , I seem not to have come across that rather > essential point it in the doc. Since you are wrong that may explain > the absence of such information. Zero is not exactly forbidden as a parameter, but the absolutes of parameters mustn´t (or rather shouldn´t) be apart by a factor of more than a few decades. 1e-30 is, well, more than thirty decades away from the values of your other parameters, and zero even more so. The fitting algorithm isn´t guaranteed to work well then, running outside of it´s specifications so to say. As HB said, if you don´t have an offset, you shoudn´t try to determine it. ;-) Same goes for a negligible offset, because then you won´t find it, but the noise in your data gets a variable fitted to it. That can´t be good. I´m not sure myself what the error message Singular matrix in Invert_RtR exactly means. It is clear that the correlation matrix cannot be calculated with variables whose absolutes are too far apart, but what is Invert_RtR ? Regards, Karl |