Packages

case class WeightedAverage(weightSum: Weight, value: Double) extends Product with Serializable

This is of course extremely similar to the averaged value implementation in Algebird... it just keeps track of a numerator AND denominator

Source
WeightedAverage.scala
Linear Supertypes
Serializable, Serializable, Product, Equals, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. WeightedAverage
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. AnyRef
  7. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new WeightedAverage(weightSum: Weight, value: Double)

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. def +(that: Double): WeightedAverage

    Returns a new instance that averages that into this instance.

    Returns a new instance that averages that into this instance.

    that

    value to average into this instance

    returns

    an instance representing the mean of this instance and that.

  4. def +(r: WeightedAverage): WeightedAverage

    Averages this instance with another WeightedAverage instance.

    Averages this instance with another WeightedAverage instance.

    r

    the other instance

    returns

    an instance representing the mean of this instance and r.

  5. def -(r: WeightedAverage): WeightedAverage

    Averages this instance with the *opposite* of the supplied WeightedAverage instance, effectively subtracting out that instance's contribution to the mean.

    Averages this instance with the *opposite* of the supplied WeightedAverage instance, effectively subtracting out that instance's contribution to the mean.

    r

    the instance to subtract

    returns

    an instance with r's stream subtracted out

  6. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  7. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  8. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  9. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  10. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  11. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  12. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  13. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  14. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  15. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  16. def plus(that: Double, weight: Weight): WeightedAverage
  17. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  18. def unary_-: WeightedAverage

    Returns a copy of this instance with a negative value.

    Returns a copy of this instance with a negative value. Note that

    a + -b == a - b
  19. val value: Double
  20. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  21. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  22. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  23. val weightSum: Weight

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from AnyRef

Inherited from Any

Ungrouped