mlr_learners_surv.bart | R Documentation |
Fits a Bayesian Additive Regression Trees (BART) learner to right-censored
survival data. Calls BART::mc.surv.bart()
from BART.
This learner returns two prediction types:
distr
: a 3d survival array with observations as 1st dimension, time
points as 2nd and the posterior draws as 3rd dimension.
Calculated using the internal predict.survbart()
function.
crank
: the expected mortality using mlr3proba::.surv_return()
. The parameter
which.curve
decides which posterior draw (3rd dimension) will be used for the
calculation of the expected mortality. Note that the median posterior is
by default used for the calculation of survival measures that require a distr
prediction, see more info on PredictionSurv.
mc.cores
is initialized to 1 to avoid threading conflicts with future.
quiet
allows to suppress messages generated by the wrapped C++ code. Is
initialized to TRUE
.
importance
allows to choose the type of importance. Default is count
,
see documentation of method $importance()
for more details.
which.curve
allows to choose which posterior draw will be used for the
calculation of the crank
prediction. If between (0,1) it is taken as the
quantile of the curves otherwise if greater than 1 it is taken as the curve
index, can also be 'mean'. By default the median posterior is used,
i.e. which.curve
is 0.5.
This Learner can be instantiated via lrn():
lrn("surv.bart")
Task type: “surv”
Predict Types: “crank”, “distr”
Feature Types: “logical”, “integer”, “numeric”
Id | Type | Default | Levels | Range |
K | numeric | NULL | [1, \infty) |
|
events | untyped | NULL | - | |
ztimes | untyped | NULL | - | |
zdelta | untyped | NULL | - | |
sparse | logical | FALSE | TRUE, FALSE | - |
theta | numeric | 0 | (-\infty, \infty) |
|
omega | numeric | 1 | (-\infty, \infty) |
|
a | numeric | 0.5 | [0.5, 1] |
|
b | numeric | 1 | (-\infty, \infty) |
|
augment | logical | FALSE | TRUE, FALSE | - |
rho | numeric | NULL | (-\infty, \infty) |
|
usequants | logical | FALSE | TRUE, FALSE | - |
rm.const | logical | TRUE | TRUE, FALSE | - |
type | character | pbart | pbart, lbart | - |
ntype | integer | - | [1, 3] |
|
k | numeric | 2 | [0, \infty) |
|
power | numeric | 2 | [0, \infty) |
|
base | numeric | 0.95 | [0, 1] |
|
offset | numeric | NULL | (-\infty, \infty) |
|
ntree | integer | 50 | [1, \infty) |
|
numcut | integer | 100 | [1, \infty) |
|
ndpost | integer | 1000 | [1, \infty) |
|
nskip | integer | 250 | [0, \infty) |
|
keepevery | integer | 10 | [1, \infty) |
|
printevery | integer | 100 | [1, \infty) |
|
seed | integer | 99 | (-\infty, \infty) |
|
mc.cores | integer | 2 | [1, \infty) |
|
nice | integer | 19 | [0, 19] |
|
openmp | logical | TRUE | TRUE, FALSE | - |
quiet | logical | TRUE | TRUE, FALSE | - |
importance | character | count | count, prob | - |
which.curve | numeric | - | [0, \infty) |
|
mlr3::Learner
-> mlr3proba::LearnerSurv
-> LearnerSurvLearnerSurvBART
new()
Creates a new instance of this R6 class.
LearnerSurvLearnerSurvBART$new()
importance()
Two types of importance scores are supported based on the value
of the parameter importance
:
prob
: The mean selection probability of each feature in the trees,
extracted from the slot varprob.mean
.
If sparse = FALSE
(default), this is a fixed constant.
Recommended to use this option when sparse = TRUE
.
count
: The mean observed count of each feature in the trees (average
number of times the feature was used in a tree decision rule across all
posterior draws), extracted from the slot varcount.mean
.
This is the default importance scores.
In both cases, higher values signify more important variables.
LearnerSurvLearnerSurvBART$importance()
Named numeric()
.
clone()
The objects of this class are cloneable with this method.
LearnerSurvLearnerSurvBART$clone(deep = FALSE)
deep
Whether to make a deep clone.
bblodfon
Sparapani, Rodney, Spanbauer, Charles, McCulloch, Robert (2021). “Nonparametric machine learning and efficient computation with bayesian additive regression trees: the BART R package.” Journal of Statistical Software, 97, 1–66.
Chipman, A H, George, I E, McCulloch, E R (2010). “BART: Bayesian additive regression trees.” The Annals of Applied Statistics, 4(1), 266–298.
Dictionary of Learners: mlr3::mlr_learners.
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.
lrn("surv.bart")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.