Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
From | raoul reulen <r.c.reulen@gmail.com> |
To | statalist@hsphsun2.harvard.edu |
Subject | st: estout p-values after lrtest |
Date | Tue, 26 Jun 2012 11:23:47 +0100 |
Hi All I am using Ben Jann's estout to store estimates in an excel table after I ran a logistic regression model. Now I also want to store p-values from a likelihood-ratio test in a separate column, but these are stored as a scalar. How do I store the p-value in a matrix? I do not want the p-value below the regression coefficient using the "stats" option, but in a separate colum on the same row as the regression coefiicient. I cannot get it done and should be grateful for any help! ***begin example** sysuse auto , clear logistic foreign headroom est store model1 logistic foreign est store model2 lrtest model1 model2 matrix pval = r(p) mat pval[1,1] = r(p) estadd matrix pval:model1 estout model1 using "example.xls" , cells("b ci pval") drop(_cons) type replace **end example*** Many thanks. Raoul * * For searches and help try: * http://www.stata.com/help.cgi?search * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/