screen.FSelector: Screening algorithms implemented in the FSelector package

View source: R/fselector.R

screen.FSelectorR Documentation

Screening algorithms implemented in the FSelector package

Description

A SuperLearner-compatible interface to functions in the FSelector package.

Usage

screen.FSelector(
  Y,
  X,
  family,
  obsWeights,
  id,
  filter = c("cfs", "chi.squared", "consistency", "gain.ratio", "information.gain",
    "linear.correlation", "oneR", "random.forest.importance", "rank.correlation",
    "relief", "symmetrical.uncertainty"),
  filter_params = NULL,
  selector = c("cutoff.biggest.diff", "cutoff.k", "cutoff.k.percent", "all"),
  k = switch(selector, cutoff.k = ceiling(0.5 * ncol(X)), cutoff.k.percent = 0.5, NULL),
  verbose = FALSE,
  ...
)

Arguments

Y

Outcome (numeric vector). See SuperLearner for specifics.

X

Predictor variable(s) (data.frame or matrix). See SuperLearner for specifics.

family

Error distribution to be used in the model: gaussian or binomial. Currently unused. See SuperLearner for specifics.

obsWeights

Optional numeric vector of observation weights. Currently unused.

id

Cluster identification variable. Currently unused.

filter

A string corresponding to a feature ranking or selecting function implemented in the FSelector package. One of: cfs, chi.squared, consistency, gain.ratio, information.gain, linear.correlation, oneR, random.forest.importance, rank.correlation, relief, symmetrical.uncertainty. Default: "cfs". Note that "filter" is a misnomer in the case of embedded feature selection methods such as random.forest.importance.

filter_params

A named list of tuning parameter arguments specific to the chosen filter. Default of NULL should be used when either 1) the chosen filter does not utilize tuning parameter(s) or 2) the default values should be retained.

selector

A string corresponding to a subset selecting function implemented in the FSelector package. One of: cutoff.biggest.diff, cutoff.k, cutoff.k.percent, or "all". Note that "all" is a not a function but indicates pass-thru should be performed in the case of a filter which selects rather than ranks features. Default: "cutoff.biggest.diff".

k

Passed through to the selector in the case where selector is cutoff.k or cutoff.k.percent. Otherwise, should remain NULL (the default). For cutoff.k, this is an integer indicating the number of features to keep from X. For cutoff.k.percent, this is instead the proportion of features to keep.

verbose

Should debugging messages be printed? Default: FALSE.

...

Currently unused.

Value

A logical vector with length equal to ncol(X).


saraemoore/SLScreenExtra documentation built on Nov. 4, 2023, 9:31 p.m.