Obtains the distribution function value for piecewise exponential regression.
ppwexp(t, theta, J, tcut, q = 0, x = 1, lower.tail = TRUE, log.p = FALSE)
The probabilities p = P(T <= t | X = x).
The vector of time points.
The parameter vector consisting of gamma for log piecewise hazards and beta for regression coefficients.
The number of time intervals.
A vector that specifies the time intervals for the piecewise exponential survival distribution. Must start with 0, e.g., c(0, 60) breaks the time axis into 2 event intervals: [0, 60) and [60, Inf). By default, it is set to 0.
The number of elements in the vector of covariates (excluding the intercept).
The vector of covariates (including the intercept).
logical; if TRUE (default), probabilities are the distribution function, otherwise, the survival function.
logical; if TRUE, probabilities p are given as log(p).