I recently read “Why Test For Proportional Hazards” by Stensrud et al. The article describes why hazard ratios are usually not proportional for medical interventions, and continues to say that when the proportional hazard assumption fails the standard errors of the Cox model with more than one covariate will be biased. The authors also warn that tests for proportional hazard violations may be underpowered and that large p-values can lull analysts into a false sense of satisfied assumptions.

To circumvent the test of proportional hazards, the authors suggest bootstrapping the Cox coefficients to give a better estimate of standard error but they don’t describe the exact bootstrap procedure. Would the following bootstrap procedure properly estimate confidence intervals without relying on the proportional hazards assumption? Are there better procedures for confidence interval estimation?

```
library(boot)
library(survival)
set.seed(42)
boot.cox <- function(df, indices) {
samples <- df[indices, ]
fit <- coxph(Surv(time, status) ~ age + factor(sex), data=samples)
coef(fit)
}
lung.boot <- boot(lung, boot.cox, 2000)
boot.ci(lung.boot, index = 1, type = "bca")
boot.ci(lung.boot, index = 2, type = "bca")
```

I’m also curious what others have to say about testing for the proportional hazards assumption, as it seems to be common practice from the tutorials and textbook discussions of Cox regression that I’ve seen.