On Tue, 06 Apr 2004 12:35:39 +0000, Roy Sanderson
<[EMAIL PROTECTED]> wrote :

>Hello
>
>I need to store the P-statistics from a number of glm objects.  Whilst it's
>easy to display these on screen via the summary() function, I'm not clear
>on how to extract the P-values and store them in a vector.

Generally when summary() functions display something, they also return
it as part of their value.  

In the case of summary() for glm objects, the table of coefficients
(including estimates, std error, z value, and p value) is returned as
a matrix in summary(glm.object)$coefficients.  You can extract the
p-values as

summary(glm.object)$coefficients[,4]

Duncan Murdoch

______________________________________________
[EMAIL PROTECTED] mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

Reply via email to