EuclideanDistanceSelector<T>

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

Euclidean Distance based Feature Selection.

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

Implements: IFixedCountFeatureSelector<T>, ISupervisedFeatureSelector<T>

For Beginners

Euclidean distance is the straight-line distance between two points. This selector finds features where different classes are far apart in space, making them easier to separate.

How It Works

Selects features that maximize class separation based on Euclidean distance between class centroids.

Constructors

Constructor Summary
EuclideanDistanceSelector(int nFeaturesToSelect, int[] columnIndices)

Properties

Property Summary
Vector<T> DistanceScores { 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)