Click or drag to resize

OrderedConnectivityMatrix Class

Class OrderedConnectivityMatrix reorders the rows and columns of an connectivity matrix so that the most affiliated elements appear as clusters of higher values along the diagonal.
Inheritance Hierarchy
SystemObject
  CenterSpace.NMath.CoreDoubleSymmetricMatrix
    CenterSpace.NMath.CoreConnectivityMatrix
      CenterSpace.NMath.CoreOrderedConnectivityMatrix

Namespace: CenterSpace.NMath.Core
Assembly: NMath (in NMath.dll) Version: 7.4
Syntax
[SerializableAttribute]
public class OrderedConnectivityMatrix : ConnectivityMatrix

The OrderedConnectivityMatrix type exposes the following members.

Constructors
 NameDescription
Public methodOrderedConnectivityMatrix(ConnectivityMatrix) Constructs an OrderedConnectivityMatrix instance using the default linkage and distance functions to perform the hierarchical cluster analysis. The default linkage function is weighted average and the default distance function is dist(i,j) = 1 - aij, where aij is the ijth entry in the connectivity matrix A.
Public methodOrderedConnectivityMatrix(ConnectivityMatrix, LinkageFunction) Constructs an OrderedConnectivityMatrix instance using the specified linkage and default distance functions to perform the hierarchical cluster analysis.
Public methodOrderedConnectivityMatrix(ConnectivityMatrix, OrderedConnectivityMatrixElementDistance) Constructs an OrderedConnectivityMatrix instance using the default linkage and specified distance functions to perform the hierarchical cluster analysis.
Public methodOrderedConnectivityMatrix(ConnectivityMatrix, OrderedConnectivityMatrixElementDistance, LinkageFunction) Constructs an OrderedConnectivityMatrix instance using the specified linkage and distance functions to perform the hierarchical cluster analysis.
Top
Properties
 NameDescription
Public propertyCols Gets the number of columns in the matrix.
(Inherited from DoubleSymmetricMatrix)
Public propertyCopheneticDistances Gets the vector of cophenetic distances between all possible element pairs resulting from the hierarchical cluster analysis.
Public propertyDataVector Gets the data vector referenced by this matrix.
(Inherited from DoubleSymmetricMatrix)
Public propertyDistanceFunction Gets and the distance function used in the hierarchical cluster analysis.
Public propertyDistances Gets the vector of distances between all possible object pairs, computed using the current distance delegate.
Public propertyItem Gets and sets the value at the specified position. Symmetry is maintained.
(Inherited from DoubleSymmetricMatrix)
Public propertyLabels Gets and sets the labels for the rows/columns of the connectivity matrix.
(Inherited from ConnectivityMatrix)
Public propertyLinkageFunction Gets the complete hierarchical linkage tree, computed from Distances using the current linkage delegate.
Public propertyNumberOfLabels Gets the number of row/column labels.
(Inherited from ConnectivityMatrix)
Public propertyOrder Gets the order of the matrix.
(Inherited from DoubleSymmetricMatrix)
Public propertyPermutationVector Gets the permutation vector of the node labels of the leaves of the dendrogram corresponding the hierarchical cluster analysis. Labels are zero based. The permutation vector, p, is used to reorder the connectivity matrix as follows: if A is the original connectivity matrix and C is the ordered connectivity matrix then C[i,j] = A[p[i],p[j]].
Public propertyRows Gets the number of rows in the matrix.
(Inherited from DoubleSymmetricMatrix)
Top
Methods
 NameDescription
Public methodApply(FuncDoubleVector, Double) Returns a new vector containing an element for each column or row in this matrix. The elements are the results of applying a function that takes a vector and returns a single-precision number.
(Inherited from DoubleSymmetricMatrix)
Public methodApply(FuncDouble, Double) Returns a new matrix with the same size as this matrix, whose values are the result of applying the given unary function to each element of this matrix.
(Inherited from DoubleSymmetricMatrix)
Public methodApply(FuncDouble, Double, Double, DoubleSymmetricMatrix) Returns a new matrix with the same size as this matrix, whose values are the result of applying the given binary function to each element of this matrix. The first parameter to the binary function is the matrix element; the second parameter is the corresponding element of the passed matrix.
(Inherited from DoubleSymmetricMatrix)
Public methodApply(FuncDouble, Double, Double, Double) Returns a new matrix with the same size as this matrix, whose values are the result of applying the given binary function to each element of this matrix. The first parameter to the binary function is the matrix element; the second parameter is the passed float-precision value.
(Inherited from DoubleSymmetricMatrix)
Public methodApply(FuncDouble, Int32, Double, Int32) Returns a new matrix with the same size as this matrix, whose values are the result of applying the given binary function to each element of this matrix. The first parameter to the binary function is the matrix element; the second parameter is the passed integer value.
(Inherited from DoubleSymmetricMatrix)
Public methodClone Constructs a deep copy of self.
(Inherited from ConnectivityMatrix)
Public methodCutTree Constructs the specified number of clusters from the hierarchical linkage tree.
Public methodDeepenThisCopy Guarantees that there is only one reference to the underlying data and that this data is in contiguous storage.
(Inherited from DoubleSymmetricMatrix)
Public methodEquals Tests for equality of this connectivity matrix and another connectivity matrix. Two connectivity matrices are equal if they have the same dimensions and all values are equal.
(Inherited from ConnectivityMatrix)
Public methodGetHashCode Computes hash code.
(Inherited from ConnectivityMatrix)
Public methodLeadingSubmatrix Returns the k by k upper left corner of the matrix. The matrix and the submatrix share the same data.
(Inherited from DoubleSymmetricMatrix)
Public methodResize Changes the order of this matrix to that specified, adding zeros or truncating as necessary.
(Inherited from DoubleSymmetricMatrix)
Protected methodSetLabels Sets the labels to the input values filling in with default values if there order is greater than the number of input labels.
(Inherited from ConnectivityMatrix)
Public methodShallowCopy Creates a shallow copy of this matrix.
(Inherited from DoubleSymmetricMatrix)
Public methodCode exampleToCommaSeparated Returns a formatted string representation of this matrix using commas and newlines.
(Inherited from DoubleSymmetricMatrix)
Public methodCode exampleToCommaSeparated(String) Returns a formatted string representation of this matrix using commas and newlines. Numbers are formatted using the specified format string.
(Inherited from DoubleSymmetricMatrix)
Public methodToGeneralMatrix Converts this sparse matrix to a general matrix.
(Inherited from DoubleSymmetricMatrix)
Public methodCode exampleToString Returns a formatted string representation of this matrix.

ToCommaSeparated

ToCommaSeparated(String)

ToTabDelimited

ToTabDelimited(String)


(Inherited from DoubleSymmetricMatrix)
Public methodCode exampleToString(String) Returns a formatted string representation of this matrix. Numbers are displayed using the specified format.

ToCommaSeparated

ToCommaSeparated(String)

ToTabDelimited

ToTabDelimited(String)


(Inherited from DoubleSymmetricMatrix)
Public methodCode exampleToTabDelimited Returns a formatted string representation of this matrix using tabs and newlines.
(Inherited from DoubleSymmetricMatrix)
Public methodCode exampleToTabDelimited(String) Returns a formatted string representation of this matrix using tabs and newlines. Numbers are formatted using the specified format string.
(Inherited from DoubleSymmetricMatrix)
Public methodTransform(FuncDouble, Double) Modifies the elements of this matrix by applying the given unary function to each element.
(Inherited from DoubleSymmetricMatrix)
Public methodTransform(FuncDouble, Double, Double, DoubleSymmetricMatrix) Modifies the contents of this matrix by applying the given binary function to each element. The first parameter to the binary function is the matrix element; the second parameter is the corresponding element of the passed matrix.
(Inherited from DoubleSymmetricMatrix)
Public methodTransform(FuncDouble, Double, Double, Double) Modifies the contents of this matrix by applying the given binary function to each element. The first parameter to the binary function is the matrix element; the second parameter is the passed float-precision value.
(Inherited from DoubleSymmetricMatrix)
Public methodTransform(FuncDouble, Int32, Double, Int32) Modifies the contents of this matrix by applying the given binary function to each element. The first parameter to the binary function is the matrix element; the second parameter is the passed integer value.
(Inherited from DoubleSymmetricMatrix)
Public methodTranspose Returns this matrix.
(Inherited from DoubleSymmetricMatrix)
Top
Fields
 NameDescription
Protected fieldlabels_ Lables for the items being connected.
(Inherited from ConnectivityMatrix)
Top
Remarks
The connectivity matrix a symmetric matrix, A, of non-negative values where aij is a measure of the connectivity of element i and j. The values aij may be 0 and 1 with 1 indicating that elemets i and j are adjacent and 0 indicating that they are not. They may also be floating point numbers. For example the values aij may be real numbers between 0 and 1 and indicate the probability, or belief that elements i and j are adjacent.
First a hierarchical cluster analysis is performed on the elements represented in the connectivity matrix. For the purpose of clustering the elements represented in the connectivity matrix are labeled 0, 1, 2,...,n-1, where n is the number of the elements. Given two integers, i and j, the provided distance function should return the distance between the ith and jth elements. If no distance function is provided the default distance function returns the value 1.0 - aij for the distance between the ith and jth elements, where aij is the i, jth element of the connectivity matrix A. After the hierarchical clustering process, the leaf nodes of the dendrogram produced from the results are traversed in order to produce a permutation vector. This permutation vector is used to reorder the rows and columns of the input connectivity matrix, causing the most affiliated elements to appear as clusters of higher values along the diagonal.
References: "Constructing and Reconstructing the Reorderable Matrix" Harri Siirtola1 and Erkki Mäkinen
"Concept Map: Clustering Visualizations of Categorical Domains" David Rouff and Mark McLean
See Also