Statalist


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

st: sorting a variable list within each obs.(row)


From   "Murali Kuchibhotla" <[email protected]>
To   [email protected]
Subject   st: sorting a variable list within each obs.(row)
Date   Mon, 25 Aug 2008 21:34:06 -0500 (CDT)

Hello,
      I have a dataset that looks like this:

Obs.  V1  V2  V3  V4
1     -1  -2  3   5
2     4    5  7   9

I would like to create a variable that picks out the minimum positive value 
from each row, i.e. one that picks out 3 from row 1 and 4 from row 2.How do I 
accomplish this? Thanks.


Murali


*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   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