Object/Trait

com.twitter.algebird

Metric

Related Docs: trait Metric | package algebird

Permalink

object Metric extends Serializable

A Metric[V] m is a function (V, V) => Double that satisfies the following properties:

1. m(v1, v2) >= 0 2. m(v1, v2) == 0 iff v1 == v2 3. m(v1, v2) == m(v2, v1) 4. m(v1, v3) <= m(v1, v2) + m(v2, v3)

If you implement this trait, make sure that you follow these rules.

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

Value Members

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

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

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

    Permalink
    Definition Classes
    AnyRef → Any
  4. def L1Iterable[V](implicit arg0: Monoid[V], arg1: Metric[V]): Metric[Iterable[V]]

    Permalink
  5. def L1Map[K, V](implicit arg0: Monoid[V], arg1: Metric[V]): Metric[Map[K, V]]

    Permalink
  6. def L2Iterable[V](implicit arg0: Monoid[V], arg1: Metric[V]): Metric[Iterable[V]]

    Permalink
  7. def L2Map[K, V](implicit arg0: Monoid[V], arg1: Metric[V]): Metric[Map[K, V]]

    Permalink
  8. def apply[V](v1: V, v2: V)(implicit arg0: Metric[V]): Double

    Permalink
  9. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  10. implicit val boolMetric: Metric[Boolean]

    Permalink
  11. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  12. implicit val doubleMetric: Metric[Double]

    Permalink
  13. final def eq(arg0: AnyRef): Boolean

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

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

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  16. implicit val floatMetric: Metric[Float]

    Permalink
  17. def from[V](f: (V, V) ⇒ Double): Metric[V]

    Permalink
  18. final def getClass(): Class[_]

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

    Permalink
    Definition Classes
    AnyRef → Any
  20. implicit val intMetric: Metric[Int]

    Permalink
  21. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  22. implicit def iterableMetric[V](implicit arg0: Monoid[V], arg1: Metric[V]): Metric[Iterable[V]]

    Permalink
  23. implicit val jBoolMetric: Metric[Boolean]

    Permalink
  24. implicit val jDoubleMetric: Metric[Double]

    Permalink
  25. implicit val jFloatMetric: Metric[Float]

    Permalink
  26. implicit val jIntMetric: Metric[Integer]

    Permalink
  27. implicit val jLongMetric: Metric[Long]

    Permalink
  28. implicit val jShortMetric: Metric[Short]

    Permalink
  29. implicit val longMetric: Metric[Long]

    Permalink
  30. implicit def mapMetric[K, V](implicit arg0: Monoid[V], arg1: Metric[V]): Metric[Map[K, V]]

    Permalink
  31. def minkowskiIterable[V](p: Double)(implicit arg0: Monoid[V], arg1: Metric[V]): Metric[Iterable[V]]

    Permalink
  32. def minkowskiMap[K, V](p: Double)(implicit arg0: Monoid[V], arg1: Metric[V]): Metric[Map[K, V]]

    Permalink
  33. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  34. def norm[V](v: V)(implicit arg0: Metric[V], arg1: Monoid[V]): Double

    Permalink
  35. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  36. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  37. implicit val shortMetric: Metric[Short]

    Permalink
  38. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  39. def toString(): String

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

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

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

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Serializable

Inherited from Serializable

Inherited from AnyRef

Inherited from Any

Ungrouped