search for: coxpr

Displaying 1 result from an estimated 1 matches for "coxpr".

Did you mean: copr
2012 Jun 29
1
predicting expected number of events using a coxph model
I fit a coxph model: coxphfit <- coxph(Surv(sampledLifetime, !sampledCensoredQ) ~ curpbc6 + prevpbc6, sampledTimeSeries) Now I'm trying to predict the expected number of events using a new dataset. The documentation suggests that coxPred <- predict(coxphfit, newdata = testTimeSeries, type="expected") will do what I want, but I get the error Error in model.frame.default(data = testTimeSeries, formula = Surv(sampledLifetime, : variable lengths differ (found for 'curpbc6') when I do this. The dataframes s...