you have a data set like this.
data qqq;
input name $ total;
cards;
qq 22
ww 33
qq 22
ee 44
rr 33
ww 44
;
run;
and you want output like this.........
name total
qq 22
ww 44
Do it by data set step.
Answer Posted / alok karan
data qq;
do i=1 to n by n-1;
set qqq point=i nobs=n ;
output;
end;
stop;
proc print data=qq;
run;
/*Above is more efficient program to know the first and last observation */
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
how many types prompting framework can be broken down to? : Sas-bi
what is treatment emergent events and treatment emregent adverse event
What are the new features included in the new version of SAS Programming Language?
Are you sensitive to code walk-throughs peer review or QC review?
What is factor analysis?
what is study design in while working with SAS? what are screening variables in SAS?
What is the difference between one to one merge and match merge? Give an example.
For what purposes have you used sas macros? : sas-macro
Have you ever used the SAS Debugger?
how to create the AE dataset by using SDTMIG specifications and SAP plan by using UNIX platform?
explain the main difference between the nodup and nodupkey options? : Sas-administrator
What is the difference between the proc sql and data step?
Explain bmdp procedure?
Hi,by usining ptf how we have to combine (likr merge)10 datasets at a time in the oracle database(and write a macro code also)?Like this i have a douts a lot if you dont mind may please send one text mail for me(madhusudhanap16@gmail.com)?
What is the difference between order and group variable in proc report?