the missing e(se) return matrix
| Gabriel |
One of the weird things with Stata’s postestimation returns is that it gives you the betas no problem, but there’s no obvious return for the standard error. The closest thing it gives you is
e(V), the variance-covariance matrix, which you have to process to get standard error.
sysuse auto, clear reg weight foreign length * save the return matrices matrix betas=e(b) matrix varcovar=e(V) *take the root of the diagonal of var-covar mata: st_matrix("se",sqrt(diagonal(st_matrix("varcovar")))') *combine and label the beta & se vectors into a single matrix matrix results=betas\se matrix rowname results = beta se matrix list results
(Note: I’ve just discovered the “sourcecode” WordPress format, which should avoid some previous problems I’ve had with putting code directly in posts].