Advertisement
| null |
|
[x]
Attachment Details
|
||
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33: 34: 35: 36: 37: 38: 39: 40: 41: 42: 43: 44: 45: 46: 47: 48: 49: 50: 51: 52: 53: 54: 55: 56: 57: 58: 59: 60: 61: 62: 63: 64: |
%let var1=EMPLOY;
%let var2=LEGAL;
%let var3=SOCIAL;
%let var4=SUBSTANCE;
%let var5=TECHNICAL;
%let var6=MENTAL;
%let var7=FAMILY;
%let var8=FINANCE;
%let var9=ASSAULT;
%let var10=MEDICAL;
%MACRO NEEDS;
%Do j = 1 %to 10;
proc transpose data=NEEDSPOST0 out=&&var&j (drop=_name_ _label_) prefix=&&var&j;
by DOC_ID;
id count;
var &&var&j;
run;
/*first part end*/
data &&var&j;
set &&var&j;
array &&var&j{*} $15 &&var&j1-&&var&j&MAXCNT;
array diff&&var&j{*} $15 diff&&var&j1-diff&&var&j&MXCNT;
array negdiff&&var&j{*} $15
negdiff1&&var&j-negdiff&&var&j&MXCNT;
array posdiff&&var&j{*} $15
posdiff1&&var&j-posdiff&&var&j&MXCNT;
do i=1 to &MXCNT;
diff&&var&j{i} =&&var&j{i+1}-&&var&j{i};
if diff&&var&j{i}>0 then negdiff&&var&j{i}=1; else negdiff&&var&j{i}=0;
if i=1 then totnegdiff&&var&j=negdiff&&var&j{i};
else
totnegdiff&&var&j=totnegdiff&&var&j+negdiff&&var&j{i};
if diff&&var&j{i}<=0 and diff&&var&j{i}ne . then posdiff&&var&j{i}=1; else posdiff&&var&j{i}=0;
if i=1 then totposdiff&&var&j=posdiff&&var&j{i};
else
totposdiff&&var&j=totposdiff&&var&j+posdiff&&var&j{i};
drop i;
end;
run;
%END;
%MEND NEEDS;
140 %ARRAY(abc,VALUES=A B C);
-
180
WARNING: Apparent invocation of macro ARRAY not resolved.
ERROR 180-322: Statement is not valid or it is used out of proper order.
WARNING: Apparent invocation of macro ARRAY not resolved.
141 %ARRAY(def,VALUES=D E F);
-
180
ERROR 180-322: Statement is not valid or it is used out of proper order.
WARNING: Apparent invocation of macro DO_OVER not resolved.
142 Rename %DO_OVER(abc def,PHRASE=?abc=?def);
------
180
ERROR 180-322: Statement is not valid or it is used out of proper order.
|
|
[x]
The Solution Rating System
|
||
|
With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.
Your Input Matters If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support. Thank you! |
||
|
Loading Advertisement... |