Documentation of 'smile.feature.Standardizer' Java class
Standardizer
smile.feature

Class Standardizer

  • Direct Known Subclasses:
    RobustStandardizer


    public class Standardizer
    extends FeatureTransform
    Standardizes numeric feature to 0 mean and unit variance. Standardization makes an assumption that the data follows a Gaussian distribution and are also not robust when outliers present. A robust alternative is to subtract the median and divide by the IQR by RobustStandardizer.
    • Constructor Summary

      Constructors 
      Constructor and Description
      Standardizer()
      Constructor.
      Standardizer(boolean copy)
      Constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      void learn(Attribute[] attributes, double[][] data)
      Learns transformation parameters from a dataset.
      java.lang.String toString() 
      double[] transform(double[] x)
      Transform a feature vector.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • Standardizer

        public Standardizer()
        Constructor.
      • Standardizer

        public Standardizer(boolean copy)
        Constructor.
        Parameters:
        copy - If false, try to avoid a copy and do inplace scaling instead.
    • Method Detail

      • learn

        public void learn(Attribute[] attributes,
                          double[][] data)
        Description copied from class: FeatureTransform
        Learns transformation parameters from a dataset.
        Specified by:
        learn in class FeatureTransform
        Parameters:
        attributes - The variable attributes. Of which, numeric variables will be standardized.
        data - The training data to learn scaling parameters. The data will not be modified.
      • transform

        public double[] transform(double[] x)
        Description copied from class: FeatureTransform
        Transform a feature vector.
        Specified by:
        transform in class FeatureTransform
        Parameters:
        x - a feature vector.
        Returns:
        the transformed feature value.
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object

DataMelt 3.0 © DataMelt by jWork.ORG

Ads help maintain this website.