The original question is below. Thanks to Andreas Christmann and Brian
Ripley
for the answer:
out <- glm( y~xmat, family=binomial (link=probit) )
b <- summary(out)$coef[,1]
se <- summary(out)$coef[,2]
This works. (A third column of summary()$coef provides t statistics.)
-- David Pattison
> -----Original Message-----
> From: Pattison, David H.
> Sent: Thursday, June 21, 2001 9:57 AM
> To: 's-news@lists.biostat.wustl.edu'
> Subject: Retrieving probit or logit standard errors: SUMMARY
>
> Please ignore the second question below. Karry Southworth has reminded me
> that glm will accept a regressor matrix, e.g.,
>
> glm(y~xmat).
>
> -----Original Message-----
> From: Pattison, David H.
> Sent: Thursday, June 21, 2001 9:19 AM
> To: 's-news@lists.biostat.wustl.edu'
> Subject: Retrieving probit or logit standard errors
>
>
> The function glm with family=binomial (link=probit) [or link=logit]
> will
> give the estimated coefficients and standard errors in the printed
> output. I would like to run N such probits, calculating for each
> one a
> test statistic using the estimated coefficients and standard errors,
> and
> saving each of the statistics as I go along. I have not been able
> to
> figure out how to retrieve the standard errors (or even how to
> retrieve
> the variance matrix from which they could be calculated, although
> there is a returned matrix, R, that looks like it might be used for
> this
> purpose). Is there an easy method to retrieve these standard
> errors?
>
> A related question: Is there some way to send glm a y vector and an
> x
> matrix (y,xmat), rather than a formula (y~x1+x2...)?
>
> I have using Splus 4.5 on Windows NT, but I have available Splus
> 2000
> and a preview version pf Splus 6.
>
> --------------------------------------------
>
> David Pattison
> Social Security Administration
> 500 E Street SW - 9th Floor
> Washington, DC 20254-0001
>
> Phone: 202-358-6240
> Fax: 202-358-6192
> e-mail: david.h.pattison@ssa.gov
>
|