Suppose that I have the following data:
For each id, I want to generate y1-y6, which is corresponding to the smallest to largest values of x1-x6. Any suggestion?
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input float(id x1 x2 x3 x4 x5 x6) 1 13 14 12 2 23 56 2 2 34 56 43 21 12 3 2 3 45 1 23 34 4 4 6 13 14 22 45 5 2 4 23 56 78 23 end
Comment