Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: estimation results and matrix


From   Sibel Selcuk <[email protected]>
To   [email protected]
Subject   st: estimation results and matrix
Date   Tue, 12 Oct 2004 15:36:38 -0400

Hi,
I'm trying to collect the coefficients of variable X in a matrix while
doing the regression for different age groups. However, when I run the
program, I get a message saying that "matrix operation not found".  Any
suggestions would be appreciated. Thanks.

matrix answers=J(100,1,0)
local i=23
while `i'<70 {
quietly regress y x if age==`i'
matrix answers(`i',1,0)=_b(x)
local i=`i'+1
}

*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   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