chjackson / flexsurv

The flexsurv R package for flexible parametric survival and multi-state modelling
http://chjackson.github.io/flexsurv/
53 stars 28 forks source link

Add start argument to predict.flexsurvreg method #97

Closed mattwarkentin closed 3 years ago

mattwarkentin commented 3 years ago

Hi @chjackson,

Do you think the start argument should be added to the predict.flexsurvreg method (and passed on to summary.flexsurvreg, which actually does the work)?

I don't recall if there was a reason we omitted this argument when creating the predict method. I would be happy to contribute the PR if you want this addition.

As a side note for my understanding, is there a reason why the times argument is ignored for predictions of type = "link" and predictions are made at time = 0 only?

chjackson commented 3 years ago

I can't see any reason not to add start, so happy for you to do this.

type="link" refers to the value of the location parameter of the distribution, adjusted for the covariates that you supply. I can't see how that could be described as a time dependent quantity, unlike say the survival probability or hazard.