how to display duplicated observations in a data using base
sas.
Answer Posted / m.sivakumar
data dups;
input var1;
datalines;
1
2
3
4
4
3
5
6
;
run;
proc sort data=dups;
by var1;
run;
data dups1;
set dups;
by var1;
if not(first.var1 and last.var1) then output;
run;
proc print data=dups;
run;
proc print data=dups1;
run;
| Is This Answer Correct ? | 4 Yes | 1 No |
Post New Answer View All Answers
What is by-group processing?
How do you test for missing values?
What sas features do you use to check errors and data validation?
for what purpose would you use the retain statement? : Sas programming
How are numeric and character missing values represented internally?
what are the types of interactive display types? : Sas-bi
Can you execute a macro within a macro? Describe. : sas-macro
If a variable contains only numbers, can it be a character data type?
what are the scrubbing procedures in sas? : Sas programming
Do you know the features of sas?
Name and describe few sas character functions that are used for data cleaning in brief.
What is connection profile? : sas-grid-administration
What does the RUN statement do?
How would you code a merge that will write the matches of both to one data set, the non-matches from the left-most data?
What are common programming errors committed in sas