scalation.analytics

MarkovClusteringTest

object MarkovClusteringTest extends App

The MarkovClusteringTest object is used to test the MarkovClustering class.

See also

www.cs.ucsb.edu/~xyan/classes/CS595D-2009winter/MCL_Presentation2.pdf

Linear Supertypes
App, DelayedInit, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. MarkovClusteringTest
  2. App
  3. DelayedInit
  4. AnyRef
  5. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

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 args: Array[String]

    Attributes
    protected
    Definition Classes
    App
  7. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  8. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  9. val cluster: Array[Int]

  10. def delayedInit(body: ⇒ Unit): Unit

    Definition Classes
    App → DelayedInit
  11. final def eq(arg0: AnyRef): Boolean

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

    Definition Classes
    AnyRef → Any
  13. val executionStart: Long

    Definition Classes
    App
  14. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  15. final def getClass(): Class[_]

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

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

    Definition Classes
    Any
  18. def main(args: Array[String]): Unit

    Definition Classes
    App
  19. val my: MarkovClustering

  20. final def ne(arg0: AnyRef): Boolean

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

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

    Definition Classes
    AnyRef
  23. val rg: RandomGraph

    * val g = new MatrixD ((12, 12), 0.

    * val g = new MatrixD ((12, 12), 0.0, 1.0, 0.0, 0.0, 0.0, 1.0, 1.0, 0.0, 0.0, 1.0, 0.0, 0.0, 1.0, 0.0, 1.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 1.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 1.0, 0.0, 1.0, 0.0, 0.0, 1.0, 1.0, 0.0, 0.0, 0.0, 1.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 1.0, 1.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 1.0, 1.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.)

    println ("-----------------------------------------------------------") println ("g = " + g) val mg = new MarkovClustering (g) mg.addSelfLoops () mg.normalize () println ("result = " + mg.processMatrix ()) println ("cluster = " + mg.cluster ())

    // Test the MCL Algorithm on a Markov transition matrix.

    val t = new MatrixD ((12, 12), 0.2, 0.25, 0.0, 0.0, 0.0, 0.333, 0.25, 0.0, 0.0, 0.25, 0.0, 0.0, 0.2, 0.25, 0.25, 0.0, 0.2, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.25, 0.25, 0.2, 0.2, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.25, 0.2, 0.0, 0.0, 0.0, 0.2, 0.2, 0.0, 0.2, 0.0, 0.0, 0.25, 0.25, 0.0, 0.2, 0.0, 0.25, 0.2, 0.0, 0.0, 0.0, 0.0, 0.2, 0.0, 0.0, 0.0, 0.0, 0.333, 0.0, 0.0, 0.0, 0.25, 0.0, 0.0, 0.2, 0.0, 0.0, 0.0, 0.2, 0.0, 0.25, 0.0, 0.0, 0.25, 0.0, 0.0, 0.0, 0.0, 0.0, 0.2, 0.2, 0.0, 0.0, 0.2, 0.2, 0.0, 0.2, 0.0, 0.0, 0.0, 0.0, 0.2, 0.0, 0.0, 0.0, 0.2, 0.2, 0.0, 0.2, 0.333, 0.2, 0.0, 0.0, 0.0, 0.0, 0.333, 0.25, 0.0, 0.0, 0.25, 0.0, 0.0, 0.0, 0.0, 0.0, 0.2, 0.0, 0.0, 0.0, 0.2, 0.2, 0.0, 0.2, 0.333, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.2, 0.0, 0.2, 0.333)

    println ("-----------------------------------------------------------") println ("t = " + t) val mt = new MarkovClustering (t) println ("result = " + mt.processMatrix ()) println ("cluster = " + mt.cluster ())

    // Test the MCL Algorithm on a graph represented as a sparse adjacency matrix.

    val x = new SparseMatrixD (12, 0.0) x(0) = ListMap ((1, 1.0), (5, 1.0), (6, 1.0), (9, 1.0)) x(1) = ListMap ((0, 1.0), (2, 1.0), (4, 1.0)) x(2) = ListMap ((1, 1.0), (3, 1.0), (4, 1.0)) x(3) = ListMap ((2, 1.0), (7, 1.0), (8, 1.0), (10, 1.0)) x(4) = ListMap ((1, 1.0), (2, 1.0), (6, 1.0), (7, 1.0)) x(5) = ListMap ((0, 1.0), (9, 1.0)) x(6) = ListMap ((0, 1.0), (4, 1.0), (9, 1.0)) x(7) = ListMap ((3, 1.0), (4, 1.0), (8, 1.0), (10, 1.0)) x(8) = ListMap ((3, 1.0), (7, 1.0), (10, 1.0), (11, 1.0)) x(9) = ListMap ((0, 1.0), (5, 1.0), (6, 1.0)) x(10) = ListMap ((3, 1.0), (7, 1.0), (8, 1.0), (11, 1.0)) x(11) = ListMap ((8, 1.0))

    println ("-----------------------------------------------------------") println ("x = " + x) val mx = new MarkovClustering (x) mx.addSelfLoops () mx.normalize () println ("result = " + mx.processMatrix ()) println ("cluster = " + mx.cluster ()) *

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

    Definition Classes
    AnyRef
  25. val t0: Long

  26. def toString(): String

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

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

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

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  30. val y: MatrixD

Inherited from App

Inherited from DelayedInit

Inherited from AnyRef

Inherited from Any

Ungrouped