[R] Forcing zero intercept in two predictor case - stat questionnot R question
Leeds, Mark (IED)
Mark.Leeds at morganstanley.com
Thu Oct 4 00:08:01 CEST 2007
Hi john : I just checked it with a simple example before I saw your
email and that does work. Thanks and I apologize to you
and the list for the question.
-----Original Message-----
From: John Fox [mailto:jfox at mcmaster.ca]
Sent: Wednesday, October 03, 2007 6:06 PM
To: Leeds, Mark (IED)
Cc: r-help at stat.math.ethz.ch
Subject: RE: [R] Forcing zero intercept in two predictor case - stat
questionnot R question
Dear Mark,
--------------------------------
John Fox, Professor
Department of Sociology
McMaster University
Hamilton, Ontario
Canada L8S 4M4
905-525-9140x23604
http://socserv.mcmaster.ca/jfox
--------------------------------
> -----Original Message-----
> From: r-help-bounces at r-project.org
> [mailto:r-help-bounces at r-project.org] On Behalf Of Leeds, Mark (IED)
> Sent: Wednesday, October 03, 2007 5:49 PM
> To: r-help at stat.math.ethz.ch
> Subject: [R] Forcing zero intercept in two predictor case - stat
> questionnot R question
>
> When one is doing simple regression and needs to force a zero
> intercept ( for whatever reason. I realize it's a controversial issue
> ), then subtracting the means of the left hand side and the right hand
> side from themselves does the trick. Does anyone know if there is a
> similar trick when the RHS has two variables ? Thanks.
Yes, express all three variables as deviations from their means. (This
follows from the observation that the LS regression surface goes through
the centroid of the variables.)
Regards,
John
--------------------------------------------------------
This is not an offer (or solicitation of an offer) to buy/se...{{dropped}}
More information about the R-help
mailing list