[R] Linear Regression
livia
yn19832 at msn.com
Wed Nov 7 13:14:29 CET 2007
Hello everyone,
I would like to a linear regression with the following code.
lm(a[,"fquamsci"]~., data=a)
a is a list with class "mts" "ts" , and "fquamsci" is the name of the
response variable in a. I would like to do a linear regression of "fquamsci"
to the rest of the variables. But it turns out the "fquamsci" is also
included in the explanatory variables. I tried the following, it is quite
strange that it does not work as well.
lm(a[,"fquamsci"]~.-a[,"fquamsci"], data=a)
Could anyone give me some advice?
Many thanks
--
View this message in context: http://www.nabble.com/Linear-Regression-tf4764346.html#a13626039
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help
mailing list