Statalist The Stata Listserver

[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: problem with -el- matrix function

From   Maarten buis <>
Subject   Re: st: problem with -el- matrix function
Date   Sat, 5 Aug 2006 08:18:24 +0100 (BST)

--- Zurab Sajaia <> wrote:
> writing local a=el(e(b),1,1) does not work, although matrix
> A=el(e(b),1,1) does. 

Several ways to make this work exist:
tempname a
scalar `a' = el(e(b),1,1)

local a = _b[whatever the name of the first variable is]

local vars: colnames(e(b))
tokenize `vars'
local a = _b[`1']

And I am sure others can think of even more elegant solutions.


Maarten L. Buis
Department of Social Research Methodology
Vrije Universiteit Amsterdam
Boelelaan 1081
1081 HV Amsterdam
The Netherlands

visiting adress:
Buitenveldertselaan 3 (Metropolitan), room Z434

+31 20 5986715

Try the all-new Yahoo! Mail. "The New Version is radically easier to use"  The Wall Street Journal
*   For searches and help try:

© Copyright 1996–2015 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index