MCPSelector<T>

Models & Types ยท AiDotNet.Preprocessing.FeatureSelection.Embedded

Minimax Concave Penalty (MCP) for feature selection.

Inheritance: TransformerBase<T, Matrix<T>, Matrix<T>> โ†’ MCPSelector<T>

Implements: IFixedCountFeatureSelector<T>, ISupervisedFeatureSelector<T>

For Beginners

Like SCAD, MCP is an improvement over Lasso. It strongly penalizes small coefficients (pushing them to zero) but gradually reduces the penalty for larger coefficients. This means truly important features keep their full effect while noise features are eliminated.

How It Works

MCP is a nonconvex penalty similar to SCAD that provides nearly unbiased estimates for large coefficients while inducing sparsity. It has a concave shape that reduces shrinkage bias.

Constructors

Constructor Summary
MCPSelector(int nFeaturesToSelect, double lambda, double gamma, int maxIterations, double tolerance, int[] columnIndices)

Properties

Property Summary
Vector<T> Coefficients { get; }
bool SupportsInverseTransform { get; }
int NFeaturesToSelect { get; }
int[] SelectedIndices { get; }

Methods

Method Summary
Matrix<T> FitTransform(Matrix<T> data, Vector<T> target)
bool[] GetSupportMask()
string[] GetFeatureNamesOut(string[] inputFeatureNames)
void Fit(Matrix<T> data, Vector<T> target)