Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: Re: retrieving names of regressors to display for post estimation output


From   Austin Nichols <[email protected]>
To   [email protected]
Subject   Re: st: Re: retrieving names of regressors to display for post estimation output
Date   Tue, 23 Jun 2009 15:50:25 -0400

"Nathan Danneman" <[email protected]>:
See "Macro extended functions related to matrices" at
http://stata.com/help.cgi?extended_fcn for row and column names, but
the easy way to do this kind of thing is to copy e(b) as a new matrix,
write an eclass program, and replace the elements, like so:

clear all
sysuse auto
qui reg pr mpg wei
mat b=e(b)
mat li b
prog redo_b, eclass
 forv i=1/`=colsof(b)' {
  mat b[1,`i']=`i'
 }
 eret post b
 eret di
end
redo_b


On Tue, Jun 23, 2009 at 2:22 PM, Martin Weiss <[email protected]> wrote:
>
> <>
>
> -regress- calls -_regress- which is built-in, so we cannot be sure how the output is produced. But you might want to take a look at -tabdisp-...
>
> HTH
> Martin
> _______________________
> ----- Original Message ----- From: "Nathan Danneman" <[email protected]>
> To: <[email protected]>
> Sent: Tuesday, June 23, 2009 7:56 PM
> Subject: st: retrieving names of regressors to display for post estimation output
>
>
>> Hi all,
>>
>> I am writing a post-estimation routine for stata that generates output
>> (a single number) for each regressor.  I would like to display this
>> output in a simple chart, much like the one that appears after running
>> a regression.  The routine is finished, and I currently output the
>> results into a row vector.  How can I add the variable names to this
>> vector, so that they can be paired with their respective results?
>> Further, is there a way to make the results chart more visually
>> pleasing, such as the one that comes up after running a regression?
>>
>> Thanks,
>> Nathan
>>

*
*   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/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index