Description Usage Arguments Details Value Author(s) References See Also Examples
Extends R package ncvreg to the proportional subdistribution hazards model. Penalties include LASSO, SCAD, and MCP. Userspecified weights can be assigned to the penalty for each coefficient.
1 2 3 4 
time 
vector of failure/censoring times 
fstatus 
vector with a unique code for each failure type and a separate code for censored observations 
X 
design matrix; 
failcode 
code of fstatus that denotes the failure type of interest 
cencode 
code of fstatus that denotes censored observations 
penalty 
penalty to be applied to the model. Either "LASSO", "SCAD", or "MCP" 
gamma 
tuning parameter of the MCP/SCAD penalty. Default is 2.7 for MCP and 3.7 for SCAD 
alpha 
tuning parameter indicating contributions from the MCP/SCAD penalty and the L2
penalty. 
lambda.min 
the smallest value for 
nlambda 
number of 
lambda 
a userspecified sequence of 
eps 
iteration stops when the relative change in any coefficient is less than 
max.iter 
maximum number of iterations. Default is 1000 
penalty.factor 
a vector of weights applied to the penalty for each coefficient.
The length of the vector must be equal to the number of columns of 
weighted 
if 
The crrp
function penalizes the partial likelihood of the proportional subdistribution hazards model from Fine and Gray(1999) with penalty LASSO, SCAD, and MCP. The coordinate algorithm is used for implementation. The criteria BIC
and GCV
are used to select the optimal tuning parameter.
Return a list of class crrp
with components
$beta 
fitted coefficients matrix with 
$iter 
number of iterations until convergence for each 
$lambda 
sequence of tuning parameter values 
$penalty 
same as above 
$gamma 
same as above 
$alpha 
same as above 
$loglik 
log likelihood of the fitted model at each value of

$GCV 
generalized cross validation of the fitted model at each value of

$BIC 
Bayesian information criteria of the fitted model at each value of

$SE 
matrix of standard errors with 
Zhixuan Fu <zhixuan.fu@yale.edu>
Breheny, P. and Huang, J. (2011) Coordinate descent algorithms for nonconvex penalized regression, with applications to biological feature selection. Ann. Appl. Statist., 5: 232253.
Fine J. and Gray R. (1999) A proportional hazards model for the subdistribution of a competing risk. JASA 94:496509.
Fu Z., Parikh C. and Zhou B.(2015). Penalized variable selection in competing risks regression. Manuscript submitted for publication.
gcrrp, cmprsk, ncvreg
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19  #simulate competing risks data
set.seed(10)
ftime < rexp(200)
fstatus < sample(0:2,200,replace=TRUE)
cov < matrix(runif(1000),nrow=200)
dimnames(cov)[[2]] < c('x1','x2','x3','x4','x5')
#fit LASSO
fit < crrp(ftime, fstatus, cov, penalty="LASSO")
#use BIC to select tuning parameters
beta < fit$beta[, which.min(fit$BIC)]
beta.se < fit$SE[, which.min(fit$BIC)]
#fit adaptive LASSO
weight < 1/abs(crr(ftime, fstatus, cov)$coef)
fit2 <crrp(ftime, fstatus, cov, penalty="LASSO", penalty.factor=weight, weighted=TRUE)
beta2 < fit2$beta[, which.min(fit2$BIC)]
beta2.se < fit2$SE[, which.min(fit2$BIC)]

Loading required package: survival
Loading required package: Matrix
Loading required package: cmprsk
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.