I have two data sets. Data set A has 1,000 observations and data set B (subset of data set A) with 800 observations. I want to make a data set C that ONLY has the other 200 observations from data set A.
I'm sure there is some easy code for this but I just don't know what it is. Please help!
While your code will provide the intended results, it looks horrible.
Compare this;
proc sort data=a;
by common_surveyid;
run;
proc sort data=b;
by common_surveyid;
run;
data a_b;
merge
a (in=a)
b (in=b)
;
by common_surveyid;
if a and not b;
run;
and tell me, which one is easier to read and understand for another coder?