Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: st: how to replicate Stata's random effects estimation results?
From
Stas Kolenikov <[email protected]>
To
[email protected]
Subject
Re: st: how to replicate Stata's random effects estimation results?
Date
Thu, 2 Sep 2010 17:20:49 -0500
You can probably replicate -xtreg-, re- using Mata, but to get as far
down as -regress-, you would need to perform a special transformation
of the data by the inverse square root of the covariance matrix of all
observations (the Kronecker product of the identity matrix and the
covariance matrix of residuals if the data are homoskedastic and
balanced). This will give you some insight into numerics such as
Cholesky decomposition of a matrix, but I doubt one can benefit
greatly from trying to get this by hand.
On Thu, Sep 2, 2010 at 9:02 AM, Ada Ma <[email protected]> wrote:
> Statalisters,
>
> I want to replicate Stata's Random Effects estimates using only the
> -regress- command, to gain better understanding as well as to do
> something that the current -xtreg- command wouldn't allow me to do.
>
> Do you know of any demonstration where people have been able to
> replicate Stata's RE estimates by hand? Or journal articles that
> describe exactly how the RE estimates are calculated? I have looked
> through several econometrics textbooks and it is not entirely clear.
>
> Many thanks in advance.
>
> Regards,
> Ada
>
>
> --
> Ada Ma
> Research Fellow
> Health Economics Research Unit
> University of Aberdeen, UK.
> http://www.abdn.ac.uk/heru/
> Tel: +44 (0) 1224 555189
> Fax: +44 (0) 1224 550926
> *
> * 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/
>
--
Stas Kolenikov, also found at http://stas.kolenikov.name
Small print: I use this email account for mailing lists only.
*
* 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/