Hi All,
I'm trying to calculate 95%CI of interaction terms (povcat|racecat) in PROC GENMOD. Both povcat and racecat are categorical variables. The 95% confidence intervals for RR's based on one estimate are outputted (Wald 95% CI).
I'd like to calculate 95% CI for those with two estimates (interaction terms) based on the variance by taking the square root.
My question is what is the option that I can specify in PROC GENMOD to output variance-covariance matrix V (a+b) = V(a) + V(b) - CoV (a, b)?
Thanks so much for help.
/*sashelp dataset*/
proc genmod data=sashelp.cars;
class DriveTrain(ref="Front") type(ref="SUV") origin(ref="Asia")/param=ref;
model MPG_Highway=DriveTrain type origin type|origin/dist=negbin link=log offset=ln;
run;
/*my model*/
proc genmod data=temp;
class zone(ref="0") povcat(ref="1") racecat(ref="0") agecat(ref="6")/param=ref;
model OUTCOME=zone povcat racecat1 agecat povcat|racecat
/dist=negbin link=log offset=ln maxiter=5000;
run;
ods rtf close;
data par1 (keep=PARAMETER LEVEL1 LEVEL2 RR LOW_RR UP_RR); set par;
RR= exp(estimate);
low_rr=exp(estimate-(1.96*stderr));
up_rr=exp(estimate+(1.96*stderr));
where PARAMETER not in ('Intercept','Scale');
run;
... View more