Maximum Likelihood estimation of proportional hazards models. Is deprecated,
use coxreg
instead.
mlreg(
formula = formula(data),
data = parent.frame(),
na.action = getOption("na.action"),
init = NULL,
method = c("ML", "MPPL"),
control = list(eps = 1e-08, maxiter = 10, n.points = 12, trace = FALSE),
singular.ok = TRUE,
model = FALSE,
center = TRUE,
x = FALSE,
y = TRUE,
boot = FALSE,
geometric = FALSE,
rs = NULL,
frailty = NULL,
max.survs = NULL
)
A list of class c("mlreg", "coxreg", "coxph")
with components
Fitted parameter estimates.
Covariance matrix of the estimates.
Vector of length two; first component is the value at the initial parameter values, the second componet is the maximized value.
The score test statistic (at the initial value).
The estimated linear predictors.
The martingale residuals.
The estimated baseline hazard.
Means of the columns of the design matrix.
Weighted (against exposure time) means of covariates; weighted relative frequencies of levels of factors.
Number of spells in indata (possibly after removal of cases with NA's).
Number of events in data.
Used by extractor functions.
Used by extractor functions.
The Walt test statistic (at the initial value).
The Surv vector.
Logical vector indicating the covariates that are factors.
The covariates.
Total Time at Risk.
List of levels of factors.
The calling formula.
The call.
The bootstrap sample, if requested on input.
Present if a frailty model is fitted. Equals the estimated frailty standard deviation.
The standard error of the estimated frailty standard deviation.
The method.
Did the optimization converge?
Did the optimization fail? (Is NULL
if not).
a formula object, with the response on the left of a ~ operator, and the terms on the right. The response must be a survival object as returned by the Surv function.
a data.frame in which to interpret the variables named in the formula.
a missing-data filter function, applied to the model.frame,
after any subset argument has been used. Default is
options()$na.action
.
vector of initial values of the iteration. Default initial value is zero for all variables.
Method of treating ties, "ML", the default, means pure maximum likelihood, i.e, data are treated as discrete. The choice "MPPL" implies that risk sets with no tied events are treated as in ordinary Cox regression. This is a cameleont that adapts to data, part discrete and part continuous.
a list with components eps
(convergence criterion),
maxiter
(maximum number of iterations), and silent
(logical,
controlling amount of output). You can change any component without mention
the other(s).
Not used.
Not used.
Should covariates be centered? Default is TRUE
Return the design matrix in the model object?
return the response in the model object?
No. of bootstrap replicates. Defaults to FALSE, i.e., no bootstrapping.
If TRUE
, the intensity is assumed constant within
strata.
Risk set? If present, speeds up calculations considerably.
A grouping variable for frailty analysis. Full name is needed.
Sampling of risk sets?
The use of rs
is dangerous, see note above. It can
however speed up computing time.
Göran Broström
Method ML
performs a true discrete analysis, i.e., one parameter per
observed event time. Method MPPL
is a compromize between the discrete
and continuous time approaches; one parameter per observed event time with
multiple events. With no ties in data, an ordinary Cox regression (as with
coxreg
) is performed.
Broström, G. (2002). Cox regression; Ties without tears. Communications in Statistics: Theory and Methods 31, 285--297.
coxreg
, risksets
dat <- data.frame(time= c(4, 3,1,1,2,2,3),
status=c(1,1,1,0,1,1,0),
x= c(0, 2,1,1,1,0,0),
sex= c(0, 0,0,0,1,1,1))
mlreg( Surv(time, status) ~ x + strata(sex), data = dat) #stratified model
# Same as:
rs <- risksets(Surv(dat$time, dat$status), strata = dat$sex)
mlreg( Surv(time, status) ~ x, data = dat, rs = rs) #stratified model
Run the code above in your browser using DataLab