Dear all, I found this question here (http://bbs.pinggu.org/thread-6752140-1-1.html). The data is:
There are only two groups for `id' (1 or 2). For `id=2', I'd like to keep the observations where the values of `x' of `id=2' appear in the values of `x' of `id=1'. The desired result is
Any suggestions?
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input float(id x) 1 3 1 4 1 5 1 6 2 3 2 4 2 7 2 8 end
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input float(id x) 1 3 1 4 1 5 1 6 2 3 2 4 end
Comment