## Simulating a survival data set
N=100; p=10; n=4
x=data.frame(matrix(rnorm(N*p),nrow=N,p))
beta=rnorm(n)
mx=matrix(rnorm(N*n),N,n)
fx=mx[,seq(n)]%*%beta/3
hx=exp(fx)
ty=rexp(N,hx)
tcens=1-rbinom(n=N,prob=.3,size=1)
y=Surv(ty,tcens)
data=list()
data$x<-x; data$y<-y
## Ranking the features according to their significance in the univariate cox models
out.cox<-CVrankSurv_fct(data,2,3,3,fs.method="cox.rank")
## Ranking the features according to the LASSO algorithm
## Not run:
# out.lasso<-CVrankSurv_fct(data,2,5,5,fs.method="lasso.rank")## End(Not run)
Run the code above in your browser using DataLab