Answer Posted / veerendar alugola
you can see the below example for a-z:
data ptcde;
input ptid $ test1 test2 test3 test4;
cards;
1102 56 65 66 70
1103 55 85 62 77
1104 85 71 59 66
1105 55 100 120 61
1106 90 58 65 63
;
run;
data abc;
set ptcde;
a=mean(of test1-test4);
run;
when you use a-z it will consider only the range variables.
You can find the below example for a--z;
data ptcde;
input ptid $ test1 abc def test4;
cards;
1102 56 65 66 70
1103 55 85 62 77
1104 85 71 59 66
1105 55 100 120 61
1106 90 58 65 63
;
run;
data abc;
set ptcde;
a=mean(of test1--test4);
run;
when you use a--z it will consider all the variables
irrespective of the series.
Is This Answer Correct ? | 9 Yes | 0 No |
Post New Answer View All Answers
how does sas handle missing values in assignment statements? : Sas programming
Tell me more about the parameters in macro? : sas-macro
What are the automatic variables for macro? : sas-macro
Do you need to compute new variables? If so,should you do this before you execute the report-writing procedure?
List down the reasons for choosing sas over other data analytics tools.
How long can a macro variable be? A token? : sas-macro
I have a dataset concat having variable a b & c. How to rename a b to e & f?
what is sas data set?
Have you used macros? For what purpose you have used? : sas-macro
Explain substr function?
What are the ways to do a “table lookup” in sas?
What are all the problems you faced while validating tables and reports?
: and & modifiers.
What can be the size of largest dataset in SAS?
In SAS explain which statement does not perform automatic conversions in comparisons?