powered by
Fits the BPPH model to time-to-event data.
bpph( formula, degree = NULL, data, approach = c("mle", "bayes"), dist = NULL, baseline = NULL, ... )
An object of class spbp, including component degree.
spbp
degree
a Surv object with time to event observations, right censoring status and explanatory terms.
Bernstein polynomial degree. If omitted, defaults to ceiling(sqrt(n)) for n = nrow(data) (see spbp).
ceiling(sqrt(n))
n = nrow(data)
a data.frame object.
Bayesian or maximum likelihood estimation methods, default is approach = "mle".
optional baseline specification; use bernstein(m) for the Bernstein polynomial degree.
bernstein(m)
optional alias for dist.
dist
further arguments passed to or from other methods
spbp, bppo and bpaft for other BP based models.
bppo
bpaft
library("spsurv") data("veteran", package = "survival") fit <- bpph(Surv(time, status) ~ karno + factor(celltype), data = veteran ) summary(fit)
Run the code above in your browser using DataLab