riskscore_fct: Main function of SurvRank.

Description Usage Arguments Details Value Examples

View source: R/riskscore_fct.R

Description

Main input function for SurvRank.

Usage

1
2
riskscore_fct(cv.ob, data, th = 0.5, surv.tab = c(0.5), f = NA,
  fix.var = NA, list.t = "weighted", ncl = 1, plt = F, ...)

Arguments

cv.ob

output of the CVrankSurv_fct

data

same list used as input in CVrankSurv_fct

th

Defaults to 0.5. Threshold of used features. th=0.5 majority vote approach

surv.tab

Defaults to c(0.5). Calculates for selected features survival curves. surv.tab determines quantiles of predictions.

f

Defaults to NA. ranking approach function. One of fsSurvRankConc, fsSurvRankGlmnet, fsSurvRankRf, fsSurvRankBoost, fsSurvRankCox, fsSurvRankRandCox, fsSurvRankRpart, fsSurvRankWang or NA, no calculation

fix.var

Defauts to NA. not NA, fixed number of features is calculated

list.t

Defauls to "weighted". Which toplist should be chosen? Possible choices are "weighted", "unweighted", "rank", "top1se","cluster" or "final"

ncl

Defaults to 1. Number of clusters for parallel execution.

plt

Default=F. Should plot of survival curves be generated?

...

arguments that can be passed to underlying functions, not used now

Details

details to follow

Value

Output of the riskscore_fct, basically a list containing the following elements

selnames

toplist of features that have been chosen

fixR

Matrix of survival AUCs with fixed number of features, but not fixed features!! (could also be calculated before)

model

cox model output for selected features, according to list.t

aic

AIC criterion of cox model

sum.model

summary object of the fitted cox model

concordance

concordance measure of fitted cox model

sfit

survfit object of the cox model)

pfit

predictions of the cox model (fitted values)

sfit.tab

survfit object according to surv.tab seperation

sfit.cox

Cox model on the groups generated by surv.tab

sfit.diff

surfdiff: Tests if there is a difference between two or more survival curves using the G-rho family of tests, or for a single curve against a known alternative

Additionally two plots are generated: if f is not NA, a boxplot of the survival AUCs, averaged for cross-validation iterations. The second plot shows the resulting survival curves according to surv.tab.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
## Simulating a survival data set
N=100; p=10; n=3
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
out<-CVrankSurv_fct(data,2,3,3,fs.method="cox.rank")
## Using the weighted toplist
risk<-riskscore_fct(out,data,list.t="weighted")
## Selected names
risk$selnames

SurvRank documentation built on May 30, 2017, 2:53 a.m.