Class MinimumMaximumScaler


  • public class MinimumMaximumScaler
    extends TransformerMixin<NumpyArray<Double>,​NumpyArray<Double>>
    Transform features by scaling each feature to a given range. This estimator scales and translates each feature individually such that it is in the given range on the training set, e.g. between zero and one. The transformation is given by:: X_std = (X - X.min(axis=0)) / (X.max(axis=0) - X.min(axis=0)) X_scaled = X_std * (max - min) + min where min, max = feature_range. This transformation is often used as an alternative to zero mean, unit variance scaling.
    • Constructor Detail

      • MinimumMaximumScaler

        public MinimumMaximumScaler()
        Instantiate a new object of MinimumMaximumScaler.
    • Method Detail

      • setMin

        public void setMin​(NumpyArray value)
        Sets the Per feature adjustment for minimum. Equivalent to `min - X.min(axis=0) * self.scale_`
        Parameters:
        value - The new value for min.
      • getMin

        public NumpyArray getMin()
        Gets the Per feature adjustment for minimum. Equivalent to `min - X.min(axis=0) * self.scale_`
      • setScale

        public void setScale​(NumpyArray value)
        Sets the Per feature relative scaling of the data. Equivalent to `(max - min) / (X.max(axis=0) - X.min(axis=0))`
        Parameters:
        value - The new value for scale.
      • getScale

        public NumpyArray getScale()
        Gets the Per feature relative scaling of the data. Equivalent to `(max - min) / (X.max(axis=0) - X.min(axis=0))`
      • setDataMin

        public void setDataMin​(NumpyArray value)
        Sets the Per feature minimum seen in the data
        Parameters:
        value - The new value for dataMin.
      • getDataMin

        public NumpyArray getDataMin()
        Gets the Per feature minimum seen in the data
      • setDataMax

        public void setDataMax​(NumpyArray value)
        Sets the Per feature maximum seen in the data
        Parameters:
        value - The new value for dataMax.
      • getDataMax

        public NumpyArray getDataMax()
        Gets the Per feature maximum seen in the data
      • setDataRange

        public void setDataRange​(NumpyArray value)
        Sets the Per feature range `(data_max_ - data_min_)` seen in the data
        Parameters:
        value - The new value for dataRange.
      • getDataRange

        public NumpyArray getDataRange()
        Gets the Per feature range `(data_max_ - data_min_)` seen in the data
      • setNFeaturesIn

        public void setNFeaturesIn​(long value)
        Sets the Number of features seen during `fit`.
        Parameters:
        value - The new value for nFeaturesIn.
      • getNFeaturesIn

        public long getNFeaturesIn()
        Gets the Number of features seen during `fit`.
      • setNSamplesSeen

        public void setNSamplesSeen​(long value)
        Sets the The number of samples processed by the estimator. It will be reset on new calls to fit, but increments across `partial_fit` calls.
        Parameters:
        value - The new value for nSamplesSeen.
      • getNSamplesSeen

        public long getNSamplesSeen()
        Gets the The number of samples processed by the estimator. It will be reset on new calls to fit, but increments across `partial_fit` calls.
      • setFeatureNamesIn

        public void setFeatureNamesIn​(String[] value)
        Sets the Names of features seen during `fit`. Defined only when `X` has feature names that are all strings.
        Parameters:
        value - The new value for featureNamesIn.
      • getFeatureNamesIn

        public String[] getFeatureNamesIn()
        Gets the Names of features seen during `fit`. Defined only when `X` has feature names that are all strings.
      • setClip

        public void setClip​(boolean value)
        Sets the value of Clip
        Parameters:
        value - The new value for Clip.
      • getClip

        public boolean getClip()
        Gets the value of Clip
      • setFeatureRange

        public void setFeatureRange​(double[] value)
        Sets the value of FeatureRange
        Parameters:
        value - The new value for FeatureRange.
      • getFeatureRange

        public double[] getFeatureRange()
        Gets the value of FeatureRange