Confidence Limits for a Hazard Ratio

This is a brief note about confidence interval of Hazard Ratio.

We all know that there are two common methods to compute the confidence limit for a Hazard Ratio in the SAS PHREG procedure. - Wald's Confidence Limits - Profile-Likelihood Confidence Limits

However, in R, we commonly use the confint() or summary() function to compute the CI from the coxph model, which assumes normality. So it is identical to Wald's CI.

You can also compute it manually from the EST ± SE * Z, as shown below.

m <- coxph(Surv(time, status) ~ ph.ecog , data=na.omit(lung))
ss <- summary(m)
coef <- coef(m)
se <- ss$coefficients[,"se(coef)"]
c(exp(coef - qnorm(0.975) * se), exp(coef + qnorm(0.975) * se))

But what's the weakness of Wald's CI? Refer to Why and When to Use Profile Likelihood Based Confidence Intervals

This blog says that since the standard errors of the general linear model are based on asymptotic variance, they may not be a good estimator of standard error for small samples. In particular, Wald Confidence Intervals may not perform very well. One should only use the Wald Confidence Interval if the likelihood function is symmetric about the MLE.

So what's the superiority of the Profile Likelihood CI?

In cases where the likelihood function is not symmetric about the MLE, the Profile Likelihood Based Confidence Interval serves better. This is because the Profile Likelihood Based Confidence Interval is based on the asymptotic chi-square distribution of the log likelihood ratio test statistic.

If you use the SAS PHREG procedure, you can just simply define the lr argument as pl to get the Profile Likelihood CI for the hazard ratio.

Unfortunately you cannot get it in coxph() function from the survival package. I have tried the coxphf() function from coxphf package, but the CI is not identical to SAS with a little difference in a few decimal places.

m2 <- coxphf::coxphf(formula=Surv(time, status) ~ ph.ecog, pl=FALSE, data=na.omit(lung))

Anyway, this is an alternative way to compute the Profile Likelihood CI.