Skip to contents

Variable selection with Surrogate Minimal Depth (SMD)

Usage

SurrogateMinimalDepth(RFS)

Arguments

RFS

A RandomForestSurrogates() object.

Value

A SurrogateMinimalDepth S3 list object:

  • RFS: The original RandomForestSurrogates() object.

  • selected: A character vector of the selected variable names.

  • depth: A numeric vector of the surrogate minimal depth for each variable.

  • threshold: The depth threshold used to select variables.

  • surrogates:

    • average: Total average number of surrogate variables.

    • layer: Average number of surrogate variables by layer (Named num [1:1000]).

References

Examples

# \donttest{
data("SMD_example_data")

res.smd <- SurrogateMinimalDepth(RandomForestSurrogates(
  x = SMD_example_data[, -1], y = SMD_example_data[, 1],
  num.trees = 10, s = 10, num.threads = 1
))
#> Warning: `seed` was not set. Your results may not be reproducible.
# }