GraphDegree

scalax.collection.GraphDegree
trait GraphDegree[N, E <: Edge[N], +CC <: ([X, Y <: Edge[X]] =>> GraphBase[X, Y, CC])]

Mixin for degree calculations.

Type parameters

E

the type of the edges in this graph.

N

the user type of the nodes (vertices) in this graph.

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
trait GraphLike[N, E, CC]
trait AdjacencyListBase[N, E, CC]
trait AdjacencyListGraph[N, E, CC]
class DefaultGraphImpl[N, E]
trait AdjacencyListGraph[N, E, CC]
class DefaultGraphImpl[N, E]
trait Graph[N, E]
trait GraphLike[N, E, CC]
trait Graph[N, E]
trait AnyGraph[N, E]
Show all
Self type
GraphBase[N, E, CC]

Members list

Type members

Classlikes

object Degree extends DegreeFunction

Attributes

Supertypes
trait NodeT => Int
class Object
trait Matchable
class Any
Self type
Degree.type
trait DegreeFunction extends NodeT => Int

Attributes

Supertypes
trait NodeT => Int
class Object
trait Matchable
class Any
Known subtypes
object Degree
object InDegree
object OutDegree
final class DegreeOrdering(val f: DegreeFunction) extends Ordering[NodeT]

Decreasing ordering of nodes with respect to their degree.

Decreasing ordering of nodes with respect to their degree.

Attributes

Companion
object
Supertypes
trait Ordering[NodeT]
trait Equiv[NodeT]
trait Serializable
trait Comparator[NodeT]
class Object
trait Matchable
class Any
Show all

Attributes

Companion
class
Supertypes
class Object
trait Matchable
class Any
Self type
trait Filter[T] extends T => Boolean

Attributes

Supertypes
trait T => Boolean
class Object
trait Matchable
class Any
object InDegree extends DegreeFunction

Attributes

Supertypes
trait NodeT => Int
class Object
trait Matchable
class Any
Self type
InDegree.type
object IntReverseOrdering extends Ordering[Int]

Decreasing ordering of integers.

Decreasing ordering of integers.

Attributes

Supertypes
trait Ordering[Int]
trait Equiv[Int]
trait Serializable
trait Comparator[Int]
class Object
trait Matchable
class Any
Show all
Self type
object OutDegree extends DegreeFunction

Attributes

Supertypes
trait NodeT => Int
class Object
trait Matchable
class Any
Self type
OutDegree.type

Types

Type alias for entries in degree maps returned by degreeSeqMap.

Type alias for entries in degree maps returned by degreeSeqMap.

Attributes

Value members

Concrete methods

def degreeCount(implicit nodeDegree: DegreeFunction, degreeFilter: Int => Boolean): SortedMap[Int, Int]

The degree set of this graph projected onto a map. The keys of the map are the degrees in decreasing order while the values are the number of inner nodes having the degree of the corresponding key.

The degree set of this graph projected onto a map. The keys of the map are the degrees in decreasing order while the values are the number of inner nodes having the degree of the corresponding key.

Value parameters

selects

nodes to be included by their degree.

the

degree function to apply to the nodes defaulting to Degree. Non-default predefined degree functions are InDegree and OutDegree.

Attributes

def degreeNodeSeq(implicit nodeDegree: DegreeFunction, degreeFilter: Int => Boolean): Seq[DegreeNodeSeqEntry]

The degree sequence of this graph projected onto a sequence of tuples. The first elements of the tuples are the degrees in non-increasing order while the second elements are the corresponding inner nodes.

The degree sequence of this graph projected onto a sequence of tuples. The first elements of the tuples are the degrees in non-increasing order while the second elements are the corresponding inner nodes.

Value parameters

selects

nodes to be included by their degree.

the

degree function to apply to the nodes defaulting to Degree. Non-default predefined degree functions are InDegree and OutDegree.

Attributes

def degreeNodesMap(implicit nodeDegree: DegreeFunction, degreeFilter: Int => Boolean): SortedMap[Int, Set[NodeT]]

The degree set of this graph projected onto a map. The keys of the map are the degrees in decreasing order while the values are sets of the corresponding inner nodes.

The degree set of this graph projected onto a map. The keys of the map are the degrees in decreasing order while the values are sets of the corresponding inner nodes.

Value parameters

selects

nodes to be included by their degree.

the

degree function to apply to the nodes defaulting to Degree. Non-default predefined degree functions are InDegree and OutDegree.

Attributes

def degreeSeq(implicit nodeDegree: DegreeFunction, degreeFilter: Int => Boolean): Seq[Int]

The degree sequence of this graph, that is the non-increasing sequence of degrees over all nodes.

The degree sequence of this graph, that is the non-increasing sequence of degrees over all nodes.

Value parameters

selects

nodes to be included by their degree.

the

degree function to apply to the nodes defaulting to Degree. Non-default predefined degree functions are InDegree and OutDegree.

Attributes

def degreeSet(implicit nodeDegree: DegreeFunction, degreeFilter: Int => Boolean): SortedSet[Int]

The degree set of this graph, that is the decreasing set of unique degrees over all nodes. Same as degreeSeq without duplicates.

The degree set of this graph, that is the decreasing set of unique degrees over all nodes. Same as degreeSeq without duplicates.

Value parameters

selects

nodes to be included by their degree.

the

degree function to apply to the nodes defaulting to Degree. Non-default predefined degree functions are InDegree and OutDegree.

Attributes

def maxDegree(implicit nodeDegree: DegreeFunction, degreeFilter: Int => Boolean): Int

The degree of the node having the highest degree or 0 if this graph is empty.

The degree of the node having the highest degree or 0 if this graph is empty.

Value parameters

selects

nodes to be included by their degree.

the

degree function to apply to the nodes defaulting to Degree. Non-default predefined degree functions are InDegree and OutDegree.

Attributes

def minDegree(implicit nodeDegree: DegreeFunction, degreeFilter: Int => Boolean): Int

The degree of the node having the least degree or 0 if this graph is empty.

The degree of the node having the least degree or 0 if this graph is empty.

Value parameters

selects

nodes to be included by their degree.

the

degree function to apply to the nodes defaulting to Degree. Non-default predefined degree functions are InDegree and OutDegree.

Attributes

def totalDegree(implicit nodeDegree: DegreeFunction, degreeFilter: Int => Boolean): Int

The total degree of this graph equaling to the sum of the degrees over all nodes or 0 if this graph is empty.

The total degree of this graph equaling to the sum of the degrees over all nodes or 0 if this graph is empty.

Value parameters

degreeFilter

selects nodes to be included by their degree.

nodeDegree

the degree function to apply to the nodes defaulting to Degree. Non-default predefined degree functions are InDegree and OutDegree.

Attributes