holdout.rf: Helper function for variable selection using Vita approach.

View source: R/variable_selection_vita.R

holdout.rfR Documentation

Helper function for variable selection using Vita approach.

Description

This function calculates a modified version of the permutation importance using two cross-validation folds (holdout folds) as described in Janitza et al. (2015). Note that this function is a reimplementation of the holdoutRF function in the R package ranger.

Usage

holdout.rf(
  x,
  y,
  ntree = 500,
  mtry.prop = 0.2,
  nodesize.prop = 0.1,
  no.threads = 1,
  type = "regression",
  importance = importance
)

Arguments

x

matrix or data.frame of predictor variables with variables in columns and samples in rows (Note: missing values are not allowed).

y

vector with values of phenotype variable (Note: will be converted to factor if classification mode is used).

ntree

number of trees.

mtry.prop

proportion of variables that should be used at each split.

nodesize.prop

proportion of minimal number of samples in terminal nodes.

no.threads

number of threads used for parallel execution.

type

mode of prediction ("regression", "classification" or "probability").

importance

See ranger for details.

Value

Hold-out random forests with variable importance

References

Janitza, S., Celik, E. & Boulesteix, A.-L., (2015). A computationally fast variable importance test for random forest for high dimensional data, Technical Report 185, University of Munich, https://epub.ub.uni-muenchen.de/25587.


silkeszy/Pomona documentation built on March 31, 2022, 11:13 p.m.