所以我在个人层面上有这样的数据:
ageband <- factor(0:5)
event.true <- c(1487,1863,1038,874,424,12)
event.false <- c(50997,32216,16723,12224,7990,1928)
df <- as.data.frame(cbind(ageband,event.true,event.false))
这是奇怪的部分:
results <- coxph(tsurv ~ ageband0 + ageband1 + ageband2+ ageband3 + ageband4 +ageband5, data = df)
我收到此警告消息:
Warning message:
In fitter(X, Y, strats, offset, init, control, weights = weights, :
Loglik converged before variable 1,2,3,4,5,6 ; beta may be infinite.
并且所有p值正好是1 ...
这真的很奇怪,因为在我之前没有清理的数据集中,年龄总是很重要......