Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, statalist.org is already up and running.


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

st: Save t-stats of a series of regressions to a matrix


From   Daniel Park <danielpark87@gmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   st: Save t-stats of a series of regressions to a matrix
Date   Tue, 18 Jun 2013 01:27:50 +0200

Hello everyone,

I think I have a very basic question. I am running a set of
regressions. Currently, I am trying to program the do-file. I have
understood the commands to set up the loop that is required.

However, I haven't figured out how to take the t-stat of each
"regression" and save it into a matrix/table so that I can access the
results and save them to an external table.

Basically, I am calculating the newey-west standard errors using the
nwest package. i am using nwest instead of newey because I use a
probit model and need to do some forecasting with the forecast horizon
being longer than the observation interval.

How can I, as part of a loop, run the "nwest probit depvar indepvar,
lag(x)" command, extract the tstats and save it to a certain position
in a matrix? (certain position in the matrix because I am forecasting
8 quarters ahead and would like the tstats to appear as a row in the
matrix.

In that respect (programming), Eviews was so much easier to learn.

Any help is greatly appreciated!
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index