GroupLassoSelector<T>

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

Group Lasso feature selection for selecting groups of related features.

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

Implements: ISupervisedFeatureSelector<T>

For Beginners

Sometimes features come in natural groups. For example, if you have a categorical variable converted to multiple dummy columns, you want to keep or remove ALL columns for that category together. Group Lasso ensures related features are selected or dropped as a unit.

How It Works

Extends Lasso to select entire groups of features together rather than individual features. Useful when features naturally belong to groups (e.g., dummy variables for a categorical feature, or related gene pathways).

Constructors

Constructor Summary
GroupLassoSelector(int nGroupsToSelect, int[][] groups, double alpha, int maxIterations, double tolerance, int[] columnIndices)

Properties

Property Summary
Vector<T> GroupNorms { get; }
bool SupportsInverseTransform { get; }
int NGroupsToSelect { get; }
int[] SelectedGroups { 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)