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
Hi, pls modify slight changes to the above prog.
data _null_ ;
set abc;
if tdate='18APR2008'D then
call symput('x',avg);
if tdate='21APR2008'D then
call symput('y',avg);
run;
%put _user_;
data _null_;
z=&x-&y;
put 'the difference=' z;
run;
Is This Answer Correct ? | 2 Yes | 3 No |
Post New Answer View All Answers
Are you sensitive to code walk-throughs peer review or QC review?
what is hierarchy flattening? : Sas-di
How do you add a number to a macro variable? : sas-macro
What does proc print, and proc contents are used for?
Describe a time when you were really stuck on a problem and how you solved it?
explain about data integrator metadata reports? : Sas-di
name some data transformation used in sas di? : Sas-di
Assuming {et} is randomly drawn from N(0,1) and e0 = 0, generate 200 observations of xt = et − 0.5e(t−1) and draw a line graph of xt.
i want for interview question & answer plz it need immediate send t my mail raviprakashmot@gmal.cm
what do the pad and dim functions do? : Sas programming
what are some differences between proc summary and proc means? : Sas programming
Differentiate between ceil and floor functions.
what is data governance? : Sas-di
For what purpose would you use the RETAIN statement?
Enlist the syntax rules followed in sas statements.