survsrfstack_train {survcompare} | R Documentation |
Trains the stacked ensemble of the CoxPH and Survival Random Forest
Description
Trains the stacked ensemble of the CoxPH and Survival Random Forest
Usage
survsrfstack_train(
df_train,
predict.factors,
fixed_time = NaN,
inner_cv = 3,
randomseed = NaN,
useCoxLasso = FALSE,
tuningparams = list(),
max_grid_size = 10,
verbose = FALSE
)
Arguments
df_train |
data, "time" and "event" should describe survival outcome |
predict.factors |
list of predictor names |
fixed_time |
time at which performance is maximized |
inner_cv |
number of cross-validation folds for hyperparameters' tuning |
randomseed |
random seed to control tuning including data splits |
useCoxLasso |
if CoxLasso is used (TRUE) or not (FALSE, default) |
tuningparams |
if given, list of hyperparameters, list(mtry=c(), nodedepth=c(),nodesize=c()), otherwise a wide default grid is used |
max_grid_size |
number of random grid searches for model tuning |
verbose |
FALSE(default)/TRUE |
Value
output = list(bestparams, allstats, model)
Examples
d <-simulate_nonlinear(100)
p<- names(d)[1:4]
tuningparams = list(
"mtry" = c(5,10,15),
"nodedepth" = c(5,10,15,20),
"nodesize" = c(20,30,50)
)
m_srf<- survsrf_train(d,p,tuningparams=tuningparams)
[Package survcompare version 0.3.0 Index]