DecimalScaler<T>
Models & Types ยท AiDotNet.Preprocessing.Scalers
Scales features by dividing by the smallest power of 10 greater than the max absolute value.
Inheritance: TransformerBase<T, Matrix<T>, Matrix<T>> โ DecimalScaler<T>
For Beginners
This scaler adjusts numbers to show them in appropriate decimal places:
- If your largest value is 750, it divides everything by 1,000
- So 750 becomes 0.75, 42 becomes 0.042, etc.
- All values end up between -1 and 1
This is useful when you want to keep relative sizes clear and decimal places meaningful.
How It Works
Decimal scaling transforms values to fall between -1 and 1 by dividing by an appropriate power of 10. This preserves the relative decimal positions and signs of values.
Constructors
| Constructor | Summary |
|---|---|
DecimalScaler(int[] columnIndices) |
Creates a new instance of DecimalScaler. |
Properties
| Property | Summary |
|---|---|
Vector<T> Scale { get; } |
Gets the power-of-10 scale factor for each feature computed during fitting. |
bool SupportsInverseTransform { get; } |
Gets whether this transformer supports inverse transformation. |
Methods
| Method | Summary |
|---|---|
string[] GetFeatureNamesOut(string[] inputFeatureNames) |
Gets the output feature names after transformation. |