Re: [R] A quick question about lm()

2008-07-07 Thread Tobias Verbeke
rlearner309 wrote: I have a simple regression using lm(). model <- lm(dist ~ speed, data = cars) sModel <- summary(model) If I just want to check the coefficient, I can use summary(lm())$coef; if I need the standard error, I can use summary(lm())$s, if I need the residuals, It is recommend

Re: [R] A quick question about lm()

2008-07-07 Thread Ted Harding
PS: I forgot to mention that, since the summary() of an lm() object is created by the function summary.lm(), you can find out the detail by looking under "Value:" at ?summary.lm Ted. On 07-Jul-08 14:28:23, Ted Harding wrote: > On 07-Jul-08 13:38:12, rlearner309 wrote: >> >> I have a simple re

Re: [R] A quick question about lm()

2008-07-07 Thread ONKELINX, Thierry
:[EMAIL PROTECTED] Namens Henrique Dallazuanna Verzonden: maandag 7 juli 2008 16:24 Aan: rlearner309 CC: r-help@r-project.org Onderwerp: Re: [R] A quick question about lm() If I understand correctly, try: names(summary(lm(...))) On Mon, Jul 7, 2008 at 10:38 AM, rlearner309 <[EMAIL PROTECTED]>

Re: [R] A quick question about lm()

2008-07-07 Thread Ted Harding
On 07-Jul-08 13:38:12, rlearner309 wrote: > > I have a simple regression using lm(). > If I just want to check the coefficient, I can use summary(lm())$coef; > if I need the standard error, I can use summary(lm())$s, if I need > the residuals, I can use summary(lm())$res. OK. How can I get the >

Re: [R] A quick question about lm()

2008-07-07 Thread Henrique Dallazuanna
If I understand correctly, try: names(summary(lm(...))) On Mon, Jul 7, 2008 at 10:38 AM, rlearner309 <[EMAIL PROTECTED]> wrote: > > I have a simple regression using lm(). > If I just want to check the coefficient, I can use summary(lm())$coef; if I > need the standard error, I can use summary(lm(

[R] A quick question about lm()

2008-07-07 Thread rlearner309
I have a simple regression using lm(). If I just want to check the coefficient, I can use summary(lm())$coef; if I need the standard error, I can use summary(lm())$s, if I need the residuals, I can use summary(lm())$res. OK. How can I get the R-squares and Adjusted R-squares using $...? Is there