org.apache.spark.mllib.stat

MultivariateOnlineSummarizer

class MultivariateOnlineSummarizer extends MultivariateStatisticalSummary with Serializable

:: DeveloperApi :: MultivariateOnlineSummarizer implements MultivariateStatisticalSummary to compute the mean, variance, minimum, maximum, counts, and nonzero counts for instances in sparse or dense vector format in a online fashion.

Two MultivariateOnlineSummarizer can be merged together to have a statistical summary of the corresponding joint dataset.

A numerically stable algorithm is implemented to compute the mean and variance of instances: Reference: variance-wiki Zero elements (including explicit zero values) are skipped when calling add(), to have time complexity O(nnz) instead of O(n) for each column.

For weighted instances, the unbiased estimation of variance is defined by the reliability weights: https://en.wikipedia.org/wiki/Weighted_arithmetic_mean#Reliability_weights.

Annotations
@Since( "1.1.0" ) @DeveloperApi()
Source
MultivariateOnlineSummarizer.scala
Linear Supertypes
Serializable, Serializable, MultivariateStatisticalSummary, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. MultivariateOnlineSummarizer
  2. Serializable
  3. Serializable
  4. MultivariateStatisticalSummary
  5. AnyRef
  6. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new MultivariateOnlineSummarizer()

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. def add(sample: Vector): MultivariateOnlineSummarizer.this.type

    Add a new sample to this summarizer, and update the statistical summary.

    Add a new sample to this summarizer, and update the statistical summary.

    sample

    The sample in dense/sparse vector format to be added into this summarizer.

    returns

    This MultivariateOnlineSummarizer object.

    Annotations
    @Since( "1.1.0" )
  7. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  8. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  9. def count: Long

    Sample size.

    Sample size.

    Definition Classes
    MultivariateOnlineSummarizerMultivariateStatisticalSummary
    Annotations
    @Since( "1.1.0" )
  10. final def eq(arg0: AnyRef): Boolean

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

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

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  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. def max: Vector

    Maximum value of each dimension.

    Maximum value of each dimension.

    Definition Classes
    MultivariateOnlineSummarizerMultivariateStatisticalSummary
    Annotations
    @Since( "1.1.0" )
  17. def mean: Vector

    Sample mean of each dimension.

    Sample mean of each dimension.

    Definition Classes
    MultivariateOnlineSummarizerMultivariateStatisticalSummary
    Annotations
    @Since( "1.1.0" )
  18. def merge(other: MultivariateOnlineSummarizer): MultivariateOnlineSummarizer.this.type

    Merge another MultivariateOnlineSummarizer, and update the statistical summary.

    Merge another MultivariateOnlineSummarizer, and update the statistical summary. (Note that it's in place merging; as a result, this object will be modified.)

    other

    The other MultivariateOnlineSummarizer to be merged.

    returns

    This MultivariateOnlineSummarizer object.

    Annotations
    @Since( "1.1.0" )
  19. def min: Vector

    Minimum value of each dimension.

    Minimum value of each dimension.

    Definition Classes
    MultivariateOnlineSummarizerMultivariateStatisticalSummary
    Annotations
    @Since( "1.1.0" )
  20. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  21. def normL1: Vector

    L1 norm of each dimension.

    L1 norm of each dimension.

    Definition Classes
    MultivariateOnlineSummarizerMultivariateStatisticalSummary
    Annotations
    @Since( "1.2.0" )
  22. def normL2: Vector

    L2 (Euclidian) norm of each dimension.

    L2 (Euclidian) norm of each dimension.

    Definition Classes
    MultivariateOnlineSummarizerMultivariateStatisticalSummary
    Annotations
    @Since( "1.2.0" )
  23. final def notify(): Unit

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

    Definition Classes
    AnyRef
  25. def numNonzeros: Vector

    Number of nonzero elements in each dimension.

    Number of nonzero elements in each dimension.

    Definition Classes
    MultivariateOnlineSummarizerMultivariateStatisticalSummary
    Annotations
    @Since( "1.1.0" )
  26. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  27. def toString(): String

    Definition Classes
    AnyRef → Any
  28. def variance: Vector

    Unbiased estimate of sample variance of each dimension.

    Unbiased estimate of sample variance of each dimension.

    Definition Classes
    MultivariateOnlineSummarizerMultivariateStatisticalSummary
    Annotations
    @Since( "1.1.0" )
  29. final def wait(): Unit

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

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

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Serializable

Inherited from Serializable

Inherited from AnyRef

Inherited from Any

Ungrouped