Re: [R] How to extract estimates, Std. Error, t Value and Pr(>|t|) from summary

From: Yasir Kaheil <kaheil_at_gmail.com>
Date: Fri, 16 May 2008 06:35:07 -0700 (PDT)

> dat<-array(runif(30),c(15,2));
> dat<-data.frame(x=dat[,1],y=dat[,2]);
> linm<-lm(y~x,data=dat);
> linm.s<-summary(linm);
> attributes(linm.s) #to see all attributes of the summary
$names

 [1] "call"          "terms"         "residuals"     "coefficients" 
 [5] "aliased"       "sigma"         "df"            "r.squared"    
 [9] "adj.r.squared" "fstatistic"    "cov.unscaled" 

$class
[1] "summary.lm"

> linm.s$coefficients # that's the variable you're looking for, right?

              Estimate Std. Error t value Pr(>|t|) (Intercept) 0.6132455 0.1907463 3.214980 0.006769529 x -0.3648345 0.3134967 -1.163759 0.265436835

thanks
y

Daphne Renault wrote:
>
>
> ______________________________________________
> 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.
>
>



Yasir H. Kaheil
Catchment Research Facility
The University of Western Ontario
-- 
View this message in context: http://www.nabble.com/How-to-extract-estimates%2C-Std.-Error%2C-t-Value-and-Pr%28%3E%7Ct%7C%29-from-summary-tp17274673p17274850.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.
Received on Fri 16 May 2008 - 13:48:36 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Fri 16 May 2008 - 15:00:41 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive