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
|
*cree une macro variable par molécule;
data _NULL_;set atc4;call symput(compress('atc4' || _N_),atc4);run;
data _NULL_;set atc4;call symput(compress('atc4t1' || _N_),atc4t1);run;
data _NULL_;set atc4;call symput(compress('atc4t2' || _N_),atc4t2);run;
data _NULL_;set atc4;call symput(compress('atc4t3' || _N_),atc4t3);run;
data _NULL_;set atc4;call symput(compress('atc4t4' || _N_),atc4t4);run;
data _NULL_;set atc4;call symput(compress('atc4t5' || _N_),atc4t5);run;
data _NULL_;set atc4;call symput(compress('atc4t6' || _N_),atc4t6);run;
data _NULL_; set atc4;call symput(compress('atc4t7' || _N_),atc4t7);run;
data _NULL_; set atc4;call symput(compress('atc4t8' || _N_),atc4t8);run;
data _NULL_; set atc4;call symput(compress('atc4t9' || _N_),atc4t9);run;
data _NULL_; set atc4; call symput(compress('atc4t10' || _N_),atc4t10);run;
data _NULL_; set atc4; call symput(compress('atc4t11' || _N_),atc4t11);run;
data _NULL_; set atc4; call symput(compress('atc4t12' || _N_),atc4t12);run;
data _NULL_;set atc4; call symput(compress('atc4t13' || _N_),atc4t13);run;
data _NULL_; set atc4; call symput(compress('atc4t14' || _N_),atc4t14);run;
data _NULL_; set atc4; call symput(compress('atc4t15' || _N_),atc4t15);run;
data _NULL_; set atc4; call symput(compress('atc4t16' || _N_),atc4t16);run;
data _NULL_; set atc4; call symput(compress('atc4t17' || _N_),atc4t17);run;
data _NULL_; set atc4;call symput(compress('atc4t18' || _N_),atc4t18);run;
data _NULL_; set atc4; call symput(compress('atc4t19' || _N_),atc4t19);run;
data _NULL_; set atc4; call symput(compress('atc4t20' || _N_),atc4t20); run;
/*stocke le nombre de molécule*/
data _NULL_;
set atc4;
call symput('nombre' , _N_);
run;
%macro essai(table);
%do i=290 %to 292;
data test.initiale;
set test.initiale;
if atc4=("&&atc4&i") and exp_acc=1 then &&atc4&i =1;else &&atc4&i=0;
if atc4t1=("&&atc4t1&i") and expo_t1=1 then &&atc4t1&i=1;else &&atc4t1&i=0;
if atc4t2=("&&atc4t2&i") and expo_t2=1 then &&atc4t2&i=1;else &&atc4t2&i=0;
if atc4t3=("&&atc4t3&i") and expo_t3=1 then &&atc4t3&i=1;else &&atc4t3&i=0;
if atc4t4=("&&atc4t4&i") and expo_t4=1 then &&atc4t4&i=1;else &&atc4t4&i=0;
if atc4t5=("&&atc4t5&i") and expo_t5=1 then &&atc4t5&i=1;else &&atc4t5&i=0;
if atc4t6=("&&atc4t6&i") and expo_t6=1 then &&atc4t6&i=1;else &&atc4t6&i=0;
if atc4t7=("&&atc4t7&i") and expo_t7=1 then &&atc4t7&i=1;else &&atc4t7&i=0;
if atc4t8=("&&atc4t8&i") and expo_t8=1 then &&atc4t8&i=1;else &&atc4t8&i=0;
if atc4t9=("&&atc4t9&i") and expo_t9=1 then &&atc4t9&i=1;else &&atc4t9&i=0;
if atc4t10=("&&atc4t10&i") and expo_t10=1 then &&atc4t10&i=1;else &&atc4t10&i=0;
if atc4t11=("&&atc4t11&i") and expo_t11=1 then &&atc4t11&i=1;else &&atc4t11&i=0;
if atc4t12=("&&atc4t12&i") and expo_t12=1 then &&atc4t12&i=1;else &&atc4t12&i=0;
if atc4t13=("&&atc4t13&i") and expo_t13=1 then &&atc4t13&i=1;else &&atc4t13&i=0;
if atc4t14=("&&atc4t14&i") and expo_t14=1 then &&atc4t14&i=1;else &&atc4t14&i=0;
if atc4t15=("&&atc4t15&i") and expo_t15=1 then &&atc4t15&i=1;else &&atc4t15&i=0;
if atc4t16=("&&atc4t16&i") and expo_t16=1 then &&atc4t16&i=1;else &&atc4t16&i=0;
if atc4t17=("&&atc4t17&i") and expo_t17=1 then &&atc4t17&i=1;else &&atc4t17&i=0;
if atc4t18=("&&atc4t18&i") and expo_t18=1 then &&atc4t18&i=1;else &&atc4t18&i=0;
if atc4t19=("&&atc4t19&i") and expo_t19=1 then &&atc4t19&i=1;else &&atc4t19&i=0;
if atc4t20=("&&atc4t20&i") and expo_t20=1 then &&atc4t20&i=1;else &&atc4t20&i=0;run; |
Partager