# Confidence interval on binomial effect size

Suppose I have a binomial test, with 9 successes in 12 trials, expected p=1/3. In other words, in R you might do:

binom.test(9,12,p=1/3)


Now, I'm under the impression that relative risk is an appropriate effect size measure. In this case, RR=0.75/(1/3)=2.25.

First - is this actually an appropriate effect size measure? Second - how would I put a confidence interval on this? The resources I have found for calculating RR confidence intervals (e.g., http://sphweb.bumc.bu.edu/otlt/mph-modules/bs/bs704_confidence_intervals/bs704_confidence_intervals8.html) assume that the p=1/3 came from a sample with a known n, rather than a theoretical probability.

The relative risk is $$\text{RR}=p/p_0$$ where $$p_0=1/3$$ in your example. The binomia count $$X$$ have distribution $$\mathcal{Bin}(n,p)$$ which we can write as $$\mathcal{Bin}(n,p_0\cdot\text{RR})$$. Then we can use a binomial regression with log link function, see Calculation of Relative Risk Confidence Interval. That gives an estimate of the RR, and we can calculate a CI by likelihood profiling. An example with your data in R:

n <- 12
x <- 9
p0 <- 1/3

mod <- glm(cbind(x, n-x) ~ offset(log(p0)), family=binomial(link="log"))
mod

Call:  glm(formula = cbind(x, n - x) ~ offset(log(p0)), family = binomial(link = "log"))

Coefficients:
(Intercept)
0.8109

Degrees of Freedom: 0 Total (i.e. Null);  0 Residual
Null Deviance:      -6.661e-16
Residual Deviance: -6.661e-16   AIC: 4.709

exp(confint(mod))
Waiting for profiling to be done...
2.5 %   97.5 %
1.416876 2.784264