Statalist


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

st: RE: about the return list of -codebook-


From   "Nick Cox" <[email protected]>
To   <[email protected]>
Subject   st: RE: about the return list of -codebook-
Date   Thu, 30 Aug 2007 23:11:15 +0100

If it did this, it would be (a) documented
and (b) evident from -return list- after 
applying the command. 

-codebook- is an r-class command, but the r-class
results issued are restricted to problem reports. 

More positively, when you say "unique" values 
I take it that you mean "distinct". Either way, 

. search unique, faq 

points to various ways of finding this out, 
including dedicated programs. One that sticks
in my mind somehow is -distinct- from SSC by
Gary Longton and another. Also you could
do something like 

. levelsof mpg, local(levels)

. di `: word count `levels'' 

Nick 
[email protected] 

Luhang Wang
 
> Does anyone know whether Stata stores the number of unique values
> after command -codebook- in any built in macro, just like r(mean) for
> mean after -sum-? 

*
*   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