select_features.FTest: Perform feature selection using the F-test method

View source: R/feature_selection.R

select_features.FTestR Documentation

Perform feature selection using the F-test method

Description

This function selects features from the input data matrix X using the F-test method and the provided feature selection specification.

Usage

## S3 method for class 'FTest'
select_features(obj, X, Y, ...)

Arguments

obj

The feature selection specification created by feature_selector().

X

The input data matrix.

Y

The response variable.

...

extra args (not used)

Details

The F-test method computes a one-way ANOVA for every column in the feature matrix.

Value

A logical vector indicating which features to retain.

See Also

feature_selector for creating a feature selection specification.

Examples

fsel <- feature_selector("FTest", "top_k", 1000)
X <- as.data.frame(matrix(rnorm(100 * 10), 100, 10))
Y <- rep(letters[1:5], 20)
selected_features <- select_features(fsel, X, Y)

bbuchsbaum/rMVPA documentation built on April 28, 2024, 6:30 a.m.