Code a PROC MEANS that shows both summed and averaged
output of the data.
Answer Posted / amit nakrani
I think we can do it in following way. Please correct me if
it is wrong.
proc means noprint data = sourcedata;
var var1 var2;
by var3;(optional)
output out = newdata
sum(var1,var2) = SumVar1 SumVar2
mean(var1,var2) = MeanVar1 MeanVar2;
run;
proc print data = newdata;
run;
Is This Answer Correct ? | 9 Yes | 2 No |
Post New Answer View All Answers
what is hierarchy flattening? : Sas-di
What is the difference between where and if statement?
what is data access? : Sas-di
What are the five ways to do a table lookup in sas? : sas-grid-administration
what other sas products have you used and consider yourself proficient in using? : Sas programming
Are you involved in writing the inferential analysis plan? Tables specifications?
Can you execute a macro within a macro? Describe. : sas-macro
Describe the ways in which you can create a macro variable?
Is the physical structure of the data set in the same orientation as the report? Do you need to reshape the data sets? What method should you use to reshape the data–DATA steps,PROC TRANSPOSE,output data set from a procedure?
why is sas data integration studio important? : Sas-di
For what purpose would you use the RETAIN statement?
What is auto call macro and how to create a auto call macro? What is the use of it? How to use it in sas with macros? : sas-macro
how to debug and test the sas program? : Sas-administrator
what is hash files in sas and why we are using this one in sas?
Hi, If anyone has base SAS certification dumps, please share.