I'm comparing various conditions versus some disease for a large stratified/clustered dataset which purports to account for the entire population after weighting -- hence the use of RR instead of OR. An epidemiologist colleague suggested that I include relative risk in my analysis, but I feel that the version of the confidence interval available on wikipedia isn't sufficient, since it doesn't take sample design into account.

Here's my SAS syntax, as recommended by the sample designers:

proc surveyfreq data=data.data_set_name;
tables disease*var1 disease*var2 disease*var1*var2;
weight WEIGHT_VAR; cluster CLUSTER_VAR;
strata STRATIFYING_VAR;
strata YEAR;
run;


My SAS output has the following columns I feel should be applicable:

Weighted Frequency (the numbers I plug into the table), and

Std Dev of Wgt Freq (actually standard error; SAS is weird).

My intuition is that $$95\%CI=\exp(m \pm 1.96s) = \exp(\ln(RR)\pm1.96s)=\exp(\ln(\frac{\frac{a}{b}}{\frac{c}{d}}))\pm1.96\sqrt{\frac{b}{a(a+b)}+\frac{d}{c(c+d)}})$$ where $s$ is the square root of the variance, might be adjustable for the standard error in some way, maybe by applying the standard error to each value and propagating to the CI somehow.

Edit: edited to include information mentioned in comments.

• Welcome to CV, Henry. I edited your question to make the math more readable. This site supports JAX which means that you can use LaTeX-style markup if you enclose it in dollar signs. (This of course is of no help if you don't use TeX or LaTeX, but if you do, now you know.) – rvl Jul 31 '14 at 1:06
• Now to your question. I don't understand what you mean by "applying the standard error to each calculation as in significant figure calculations." What is needed, it seems to me, is to ensure that the standard error, $s$, you obtain is appropriately calculated based on the design of the study. With what you say, there is no way to guess what you did in SAS to get these results. I am probably not the righht person to answer your question, but I feel that whoever is will have the same trouble as I do in understanding what you did. – rvl Jul 31 '14 at 1:13
• Hi, thanks for the edit. I was looking for a way to include LaTeX but a quick search didn't tell me that. My thought was that standard error might be applied to the terms of the relative risk CI calculation and propagate through to the CI, but that's just my intuition. Here's some example SAS code I used to obtain standard error: 'proc surveyfreq data=data.data_set_name; tables diseasevar1 diseasevar2 disease*var1*var2; weight WEIGHT_VAR; cluster CLUSTER_VAR; strata STRATIFYING_VAR; strata YEAR; run;' This corresponds to the syntax recommended by the sample designers. – Henry Gong Jul 31 '14 at 16:35
• OK. This looks like like valuable help for the users who are able to answer the question. It still looks to me like Std dev of Wgt Freq would be an SD, not an SE, but who am I to know. – rvl Jul 31 '14 at 17:47
• Yeah, here's a link to a SAS communities question from a couple years ago (from yours truly) about that strange naming decision. – Henry Gong Jul 31 '14 at 22:34