Date: Wed, 9 Jan 2008 13:57:50 -0800
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
Subject: Help with data manipulation. Thanks!!!
Content-Type: text/plain; charset=ISO-8859-1
I have a dataset which include 3 variables: id, i, j. For each id, the
values for i and j may be 1~4. It is required that the combination of
these 3 variables to be unique, which means, for example, the
combination of id=2 i=3 j=1 can be on the dataset for only one time.
If the combination shows up for two or more times on the datset, I
need keep only the first obs this combination shows up and remove
other obs it shows up.
To solve the problem, I sort the dataset according to id i j. Then I
only need to do iterations within each id. But I do not know how to do
it by SAS. Can any people help me do it?
Thanks a lot!!!