how to display duplicated observations in a data using base
sas.

Answer Posted / prakash hullathi

use frequency procedure with single column
data dups;
input var1;
datalines;
1
2
3
4
4
3
5
6
;
run;
proc freq data=dups;
tables var1/norow nocol nopercent;
run;


The output will be like this


var1 frequency cumulative frequency
1 1 1
2 1 2
3 2 4
4 2 6
5 1 7
6 1 8


here the observations for the variable var1 3 and 4 are
appered 2 times and remaining appeared for 1 time by
seeing the frequency of corresponding variable and
observation

Is This Answer Correct ?    2 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the difference between ceil and floor functions in sas?

709


how does sas handle missing values in procs? : Sas programming

637


What is the difference between nodupkey and nodup options?

597


what is hash files in sas and why we are using this one in sas?

1732


What are the different versions of sas that you have used until now? : sas-grid-administration

734






What are the data types does SAS contain?

655


I have a SCD Type 2 Dimention for Location In which A Sales Office in Having two Surrogate Keys just because of the change in it's Sales Group. SKey SalesGroup Sales Office BeginDate EndDate 280 SG1 SO1 01APR2000 01APR2010 281 SG2 SO1 02APR2010 31MAR2999 Now while loading the Fact, the Lookup ir returning SKey 280 for records before and after 01APR2010. I am not able to give WHERE condition in the Lookup Properties (TranDate between BeginDate and EndDate). Please help.

1698


Name types of category in which SAS Informats are placed?

737


Which function is used to count the number of intervals between two sas dates?

570


How sas treats the dsd delimiters?

724


explain the difference between alternate key, business key, foreign key, generated key, primary key, retained key and surrogate key ? : Sas-di

544


what is the difference between infile and input? : Sas-administrator

610


How do you control the number of observations and/or variables read or written?

750


I am preparing SAS Certified Advanced Programmer for SAS 9 in 2014. If anybody has the latest dumps for this exam, please mail me at dhiman.mukherjee@gmail.com

2262


what is sas olap server? : Sas-di

689