DATA ABC;
INPUT TDATE DATE9. AVG;
CARDS;
18APR2008 150.00
19APR2008 167.00
20APR2008 123.00
21APR2008 145.00
;
RUN
HOW CAN I FIND THE DIFFERENCE BETWEEN AVG OF 18APR2008 ANF
21APR2008??
IF ANY ONE GETS IT PLS TRY TO POST IT.
Answer Posted / rajaanku11
DATA ABC;
INPUT TDATE DATE9. AVG;
CARDS;
18APR2008 150.00
19APR2008 167.00
20APR2008 123.00
21APR2008 145.00
;
RUN;
data _null_;
set abc;
if tdate='18APR2008'D then
call symput('x',avg);
if tdate='21APR2008'D then
call symput('y',avg);
z=&x-&y;
run;
data _null_;
z=&x-&y;
put 'the difference='z;
run;
| Is This Answer Correct ? | 2 Yes | 4 No |
Post New Answer View All Answers
which features do you use to check the data validations and errors? : Sas-administrator
Enlist the syntax rules followed in sas statements.
Of all your work, where have you been the most successful?
Define run-group processing?
what is the primary data source for the wrs? : Sas-bi
What is the purpose of _character_ and _numeric_?
Compare sas with other data analytics tools.
List out some key concept of SAS
what is the difference between floor and ceil functions in sas? : Sas-administrator
Explain the difference between nodup and nodupkey options?
What is SAS?
How would you identify a macro variable?
Did you used proc test? when?
what is sas database server? : Sas-di
What is the general format of function in sas? : sas-grid-administration