Hello.
i have problem when running risk set sampling macro.
i found this macro on this(http://mchp-appserv.cpe.umanitoba.ca/Upload/SAS/risk_set_sampling_macro.sas.txt)
this is my marco typing on SAS
%risk_set_match (cohort_name = CASE_CTRL,
outcome_var = outcome,
end_fu = END_EPI,
randnum = 123,
K = 20,
control_index_dt = case_fu,
rs_match_where = a.sex=b.sex
id = JID,
time0 = START_EPI,
gender = sex,
agevar = age,
output_name = matched1,
no_match = N
);
In the middle of macro, there is
-----------------------------------------------------------
proc sql;
create table risk as
select
a.&id. as case_ID,
b.&id. as control_ID,
a.&agevar. as case_age,
b.&agevar. as control_age,
a.&gender. as case_sex,
b.&gender. as control_s,
a.&time0. as case_t0,
b.&time0. as control_t0,
a.&end_fu. as case_endfu,
b.&end_fu. as control_endfu,
a.caco as case_caco,
b.caco as control_caco,
a.index_date,
a.match_num
from case_caco1_I a,
controls b
where &rs_match_where;
quit;
proc append base = risk_set data = risk;
run;
----------------------------------------------------------------
In here such as case_ID, from ~~~, i have got errors.
ERROR 22-322 ~~~~
please answer me TT