Accepted Solution

6-ways of removing duplicate

Reply
Super User
Posts: 10,200

Re: 6-ways of removing duplicate

Posted in reply to CharlotteCain

Hi.Charlotte,

That is Uma did.

Data Dup;

     set temp;

     by variable;

     if not first.variable and last.variable;

     run;

You also can get duplicated obs  by using the methods I mentioned before .

Ksharp

Frequent Contributor
Posts: 81

Re: 6-ways of removing duplicate

Thanx PG State for providing a ans.

Contributor
Posts: 64

Re: 6-ways of removing duplicate

Posted in reply to umashankersaini

Hi Uma,

Can you please explaint the 4th way of removing the duplicate.

PROC Star
Posts: 7,638

Re: 6-ways of removing duplicate

Posted in reply to Rahul_SAS

It is similar to Uma's incorrect application of #5.  It identifies values of "variable" where there aren't any duplicates (i.e., if count is gt 1 then there were more than one record which had the same value of variable.

Contributor
Posts: 63

Re: 6-ways of removing duplicate

Posted in reply to umashankersaini

hi all,

there is another method to eliminate duplicate values by using proc summary with nway option and class statement.

Frequent Contributor
Posts: 118

Re: 6-ways of removing duplicate

Posted in reply to AnandSahu

Apologies for 5th one....Thanks for correcting that....

Contributor
Posts: 56

Re: 6-ways of removing duplicate

Posted in reply to umashankersaini

(4) is wrong uma

Contributor
Posts: 56

Re: 6-ways of removing duplicate

Posted in reply to shivakrishna

how in below methods

6.proc means;

7.proc summary;

8.HashTable

9. proc tabulate

10.proc report

☑ This topic is solved.

Need further help from the community? Please ask a new question.

Discussion stats
  • 37 replies
  • 46493 views
  • 20 likes
  • 14 in conversation