Skip to content

Running glm in batch and exporting results (AIC) to HTML

3 messages · Jérôme Lemaître, vincent@7d4.com, stefano iacus

#
Dear all,

I'm doing univariate Poisson regressions using the "glm" and "glm.fit"
functions. I have 5 independent datasets and each dataset, has one response
variable and more than 20 factors to test.
Currently, I run one regression at a time and manually take notes of the
results in excel to have a quick overview on what is going on in my data. My
poor method is very time-consuming and I was looking for a faster and more
reliable way to do all the regressions.
I'm quite sure that R could do all of this for me but I can't think of a way
to tell it...

What I want R to do is
1) running one regression at a time in a particular dataset.
2) saving results. Here, I'm interested in AIC, Beta coefficient of the
factor, the z value and the p value of the factor
3) formatting results in a table with column names as follow:
factor; beta coefficient; z value; p value; aic
4) exporting the table in a way that I could read it in excel. In that way,
I would repeat the operation for each of the 5 datasets rather than for the
100 regressions.

I hope you could help me with this.
Thanks a lot for your answers.

J??r??me Lema??tre
Ph.D. student
Dpt biologie
Universit?? Laval
Qu??bec, Canada
#
see

?html

in Hmisc package

HIH
Ste
On Tue, Sep 20, 2005 at 02:56:17PM +0200, vincent at 7d4.com wrote:
<vincent>see
<vincent>?write.table
<vincent>hih
<vincent>
<vincent>______________________________________________
<vincent>R-help at stat.math.ethz.ch mailing list
<vincent>https://stat.ethz.ch/mailman/listinfo/r-help
<vincent>PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html