[R] Re siduals from a linear model

Greg Snow Greg.Snow at imail.org
Tue Nov 18 19:51:02 CET 2008


To get at the effect of d in the model y~ a+b+c+d you need to look at the regression of the residuals of y ~ a+b+c on the residuals of  d ~ a+b+c, that should give you the same results/significance as d in the full model.  If you only regress the residuals against d, then that does not adjust for the relationship between d and a, b, and c as the full model does.

Hope this helps,

--
Gregory (Greg) L. Snow Ph.D.
Statistical Data Center
Intermountain Healthcare
greg.snow at imail.org
801.408.8111

> -----Original Message-----
> From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-
> project.org] On Behalf Of Manuel Ramon
> Sent: Tuesday, November 18, 2008 2:23 AM
> To: r-help at r-project.org
> Subject: [R] Re siduals from a linear model
>
>
> I'm working with a linear model with four factors as explicatory
> variables,
> being all of them significally (e.g. y ~ a + b + c + d). I thought that
> the
> residuals of a linear model keep the variance not explained by the
> model, so
> if I use my model with just three factors (y ~ a + b + c) and keep the
> residuals is expected that in a new model with the residuals as
> dependent
> variable and the four factor as independent (residuals ~ d) that factor
> (d)
> will be significally. Is that truth or not?
>
>
>
> -----
> Manuel Ramón Fernández
> Group of Reproductive Biology (GBR)
> University of Castilla-La Mancha (Spain)
> mramon at jccm.es
> --
> View this message in context: http://www.nabble.com/Residuals-from-a-
> linear-model-tp20556033p20556033.html
> Sent from the R help mailing list archive at Nabble.com.
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-
> guide.html
> and provide commented, minimal, self-contained, reproducible code.


More information about the R-help mailing list