ROCSI | R Documentation |
function for ROCSI
ROCSI( Dtrain, Dtest = NULL, yvar, xvars, trtvar, cvar = NULL, nfolds = 5, type = "binary" )
Dtrain |
data matrix for training dataset |
Dtest |
optional data matrix for testing dataset |
yvar |
column name for outcome |
xvars |
a string vector of column names for input markers |
trtvar |
column name for treatment (the column should contain binary code with 1 being treatment and 0 being control) |
cvar |
column name for censor (the column should contain binary code with 1 being event and 0 being censored) |
nfolds |
n fold CV used for cv.glmnet |
type |
outcome type ("binary" for binary outcome and "survival" for time-to-event outcome) |
function for ROCSI
A list with ROCSI output
final beta estimated from ROCSI based on ABC^{(acv)}
final beta estimated from lambda.1se based on nfold CV
optimal lambda selected by optimizing ABC^{(acv)}
fitted cv.glmnet model
log matrix of all lambdas and ABCs
ABC in testing dataset based on optimal beta
ABC in testing dataset based on 1se beta
a data.frame of testing data and its predictive signature scores (based on beta.aABC) for each subjects
a data.frame of testing data and its predictive signature scores (based on beta.1se) for each subjects
n <- 100 k <- 5 prevalence <- sqrt(0.5) rho<-0.2 sig2 <- 2 rhos.bt.real <- c(0, rep(0.1, (k-3)))*sig2 y.sig2 <- 1 yvar="y.binary" xvars=paste("x", c(1:k), sep="") trtvar="treatment" prog.eff <- 0.5 effect.size <- 1 a.constent <- effect.size/(2*(1-prevalence)) ObsData <- data.gen(n=n, k=k, prevalence=prevalence, prog.eff=prog.eff, sig2=sig2, y.sig2=y.sig2, rho=rho, rhos.bt.real=rhos.bt.real, a.constent=a.constent) TestData <- data.gen(n=n, k=k, prevalence=prevalence, prog.eff=prog.eff, sig2=sig2, y.sig2=y.sig2, rho=rho, rhos.bt.real=rhos.bt.real, a.constent=a.constent) bst.aabc <- ROCSI(Dtrain=ObsData$data, Dtest = TestData$data, yvar=yvar, xvars=xvars, trtvar=trtvar, cvar=NULL, nfolds=5, type="binary") bst.aabc$beta.aABC bst.aabc$log bst.aabc$abc.test bst.aabc$beta.1se bst.aabc$abc.test1se
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.