Dear Statalist users,
I am using the 'actest' command to conduct a serial correlation test after time-series regressions. However, I need to repeat the test 48 times (i.e., after each of the 48 regressions). So, I am trying to write a Stata code that generates the results automatically as follows:
matrix autocorr=J(48,7,.)
local i=1
forvalues j = 1/48 {
reg y x1 x2 x3 x4 if id==`j', robust
actest, r q0 lag(1/3)
matrix [`i',1]=(r(p))
i=`i'+1
}
matrix list autocorr
I get the message:
matrix operation not found
r(501);
I need help on how to fix the issue.
Thanks in advance for your reply.
Emna
Related Posts with Store p-values in a matrix after 'actest'
Help with one step system gmmHello, my case is described below and I would like help on how should I run One step system GMM usin…
Problem with calculating employment (unemployment) duration until first unemployment (employment)Hello everyone, I have trouble working with duration data. I am working with spell-type data. The …
Problem with 11x11 correlation matrix in SEMHi All, I am trying to run an SEM model with specified number of observations, means, SDs, and corr…
Average values of dependent variableHi everyone, I have one question which is a little bit harder to explain but I will give my best. …
Multiple-answer questions: When to reduce multivariate to univariate probit?Problem description Assume there are individuals j who each need to choose from two alternatives i=…
Subscribe to:
Post Comments (Atom)
0 Response to Store p-values in a matrix after 'actest'
Post a Comment