On 05-Dec-04 Peter Dalgaard wrote:
> Peter Dalgaard <[EMAIL PROTECTED]> writes:
>> Re. the smoothed residuals, you do need to be careful about the
>> smoother. Some of the "robust" ones will do precisely the wrong thing
>> in this context: You really are interested in the mean, not some
>> trimmed mean (which can easily amount to throwing away all your
>> cases...). Here's an idea:
>> 
>> x <- runif(500)
>> y <- rbinom(500,size=1,p=plogis(x))
>> xx <- predict(loess(resid(glm(y~x,binomial))~x),se=T)
>> matplot(x,cbind(xx$fit, 2*xx$se.fit, -2*xx$se.fit),pch=20)
>> 
>> Not sure my money isn't still on the splines, though.
> 
> Doh. You might also want to make sure that the residuals are of a type
> that can be _expected_ to have mean zero. Apparently, the default
> deviance residuals do not have that property, whereas response
> residuals do. I did check that loess (as opposed to lowess!) does a
> plain least-squares based fitting by default, but I didn't think to
> check what kind of residuals I was looking at.
> 
> Serves me right for posting way beyond my bedtime...

Hi Peter,

Yes, the above is certainly misleading (try it with 2000 instead
of 500)! But what would you suggest instead?

Thanks,
Ted.


--------------------------------------------------------------------
E-Mail: (Ted Harding) <[EMAIL PROTECTED]>
Fax-to-email: +44 (0)870 094 0861  [NB: New number!]
Date: 05-Dec-04                                       Time: 19:38:00
------------------------------ XFMail ------------------------------

______________________________________________
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

Reply via email to