Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at

[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 <>
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

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

Any help is greatly appreciated!
*   For searches and help try:

© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index