Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: RE: rank error?


From   Jeph Herrin <[email protected]>
To   [email protected]
Subject   Re: st: RE: rank error?
Date   Wed, 28 May 2003 08:20:14 -0400

Nick Cox wrote:


If one wants to do a certain operation on all obs with -var1-==X,
indexing through all the values of X, and do so in order of increasing
X, then the value of such a ranking becomes obvious.


Now we have convergence. Try -egen, group()-.
Not clear to me that -group(X)- assigns values in
order of increasing  X (even if, as E Berkhout suggests
in a separate posting, I sort -sort X- first).



BTW: have a look also at -levels-.
Same problem. Not clear that -levels- returns a list that
is sorted in increasing order. Plus, in my particular
case I have non-integers (though that's easily gotten
around).

cheers,
Jeph




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