Displaying 1 result from an estimated 1 matches for "y5_flex".
Did you mean:
k56flex
2024 May 14
0
flexsurvspline with offset
...with(rotterdam, ifelse(recur==1, rtime, dtime))
fit1 <- flexsurvspline(Surv(rfstime, rfs) ~ age + meno + size + er, k=2, data = rotterdam)
# obtain the linear predictor for each patient
predf <- model.matrix(fit1) %*% fit1$res[-(1:4),"est"]
# Predict baseline survival at 5 years
y5_Flex_1 <- summary(fit1,type="survival",t=5)
y5_Flex <- y5_Flex_1[[1]]$est
y5_Flex
# Shrinkage factor
vanH <- 0.9589255
heuristic_lp_flex = vanH*predf??????
# Now calculate the shrunken model baseline survival prob at 5 years by fixing the shrunken lp as an offset and predicting the...