Category:Pre-processing in R: Feature Selection

Sequential replacement - regsubsets from the R library ‘leaps’ can be used. For example: to implement forward selection, specify the method type as 'forward'.

Factor Analysis - Function fa from the r package psych can be used. The function takes the following primary arguments. extracted (default = 1) such as "varimax" or "oblimin" "pa" (principal axis) or "ml" (maximum likelihood)
 * r: the correlation matrix
 * 1) nfactors: number of factors to be
 * 1) rotate: one matrix rotation methods,
 * fm: one factoring methods, such as

Ranking Attributes - relief function from the FSelector package can be used. The algorithm finds weights of continuous and discrete attributes based on a distance between instances. Sample size and the neighbors count can be passed as an argument to the function. Note - can be time expensive.

The following functions under the FSelector package can be used for feature selection.

cfs(formula, data)  - can be used for correlation based feature selection.

information.gain(formula, data)--- can be used for feature selection based on information gain

Here formule can be written as class~. (class is the class attribute)