Survival Akritas Estimator Learner
mlr_learners_surv.akritas.Rd
Survival akritas estimator.
Calls survivalmodels::akritas()
from package 'survivalmodels'.
Meta Information
Task type: “surv”
Predict Types: “crank”, “distr”
Feature Types: “logical”, “integer”, “numeric”, “character”, “factor”
Required Packages: mlr3, mlr3proba, mlr3extralearners, survivalmodels, distr6
Parameters
Id | Type | Default | Levels | Range |
lambda | numeric | 0.5 | \([0, 1]\) | |
reverse | logical | FALSE | TRUE, FALSE | - |
ntime | numeric | 150 | \([1, \infty)\) | |
round_time | integer | 2 | \([0, \infty)\) |
Installation
Package 'survivalmodels' is not on CRAN and has to be install from GitHub via
remotes::install_github("RaphaelS1/survivalmodels")
.
References
Akritas, G M (1994). “Nearest neighbor estimation of a bivariate distribution under random censoring.” The Annals of Statistics, 1299–1327.
See also
as.data.table(mlr_learners)
for a table of available Learners in the running session (depending on the loaded packages).Chapter in the mlr3book: https://mlr3book.mlr-org.com/basics.html#learners
mlr3learners for a selection of recommended learners.
mlr3cluster for unsupervised clustering learners.
mlr3pipelines to combine learners with pre- and postprocessing steps.
mlr3tuning for tuning of hyperparameters, mlr3tuningspaces for established default tuning spaces.
Super classes
mlr3::Learner
-> mlr3proba::LearnerSurv
-> LearnerSurvAkritas
Examples
# Define the Learner
learner = mlr3::lrn("surv.akritas")
print(learner)
#> <LearnerSurvAkritas:surv.akritas>: Akritas Estimator
#> * Model: -
#> * Parameters: list()
#> * Packages: mlr3, mlr3proba, mlr3extralearners, survivalmodels, distr6
#> * Predict Types: [crank], distr
#> * Feature Types: logical, integer, numeric, character, factor
#> * Properties: -
# Define a Task
task = mlr3::tsk("grace")
# Create train and test set
ids = mlr3::partition(task)
# Train the learner on the training ids
learner$train(task, row_ids = ids$train)
print(learner$model)
#>
#> Akritas Estimator
#>
#> Call:
#> survivalmodels::akritas(data = data.table::setDF(task$data()), time_variable = task$target_names[1L], status_variable = task$target_names[2L])
#>
#> Response:
#> Surv(time, status)
#> Features:
#> {age, los, revasc, revascdays, stchange, sysbp}
# Make predictions for the test rows
predictions = learner$predict(task, row_ids = ids$test)
# Score the predictions
predictions$score()
#> surv.cindex
#> 0.5