[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: extracting matrix row to macro

From   Eva Poen <>
Subject   Re: st: extracting matrix row to macro
Date   Sun, 28 Jun 2009 15:51:16 +0100


You can use -levelsof- for this task:

levelsof x if y > 40, local(mymacro)

The levels of x will be stored in the macro mymacro. You can add
delimiters if you want.


2009/6/28 Reed Walker <>:
> I am tabulating a variable and getting a series of frequencies and unique
> values.
> I am interested in using the unique values later in the program.
> tabulate x if y>40, matcell(m) matrow(m1)
> Thus, I want to put the contents of matrix m1 (a vector) into a local macro.
> There must be an easy way to do this, but I have thus far come up short.
*   For searches and help try:

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