org.apache.mahout.math.algorithms.preprocessing

StandardScaler

class StandardScaler extends PreprocessorFitter

Scales columns to mean 0 and unit variance

An important note- The equivelent call in R would be something like r N <- nrow(x) scale(x, scale= apply(x, 2, sd) * sqrt(N-1/N))

This is because R uses degrees of freedom = 1 to calculate standard deviation. Multiplying the standard deviation by sqrt(N-1/N) 'undoes' this correction.

The StandardScaler of sklearn uses degrees of freedom = 0 for its calculation, so results should be similar.

Linear Supertypes
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. StandardScaler
  2. PreprocessorFitter
  3. UnsupervisedFitter
  4. Fitter
  5. AnyRef
  6. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new StandardScaler()

Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  7. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  9. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  10. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  11. def fit[K](input: DrmLike[K], hyperparameters: (Symbol, Any)*): StandardScalerModel

  12. def fitTransform[K](input: DrmLike[K], hyperparameters: (Symbol, Any)*): DrmLike[K]

    Definition Classes
    PreprocessorFitter
  13. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  14. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  15. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  16. var model: PreprocessorModel

    Definition Classes
    PreprocessorFitter
  17. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  18. final def notify(): Unit

    Definition Classes
    AnyRef
  19. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  20. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  21. def toString(): String

    Definition Classes
    AnyRef → Any
  22. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  23. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  24. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from PreprocessorFitter

Inherited from UnsupervisedFitter

Inherited from Fitter

Inherited from AnyRef

Inherited from Any

Ungrouped