Click or drag to resize

NMFConsensusMatrixAlg Class

Class NMFConsensusMatrix uses a non-negative matrix factorization to cluster samples.
Inheritance Hierarchy
SystemObject
  CenterSpace.NMath.CoreDoubleSymmetricMatrix
    CenterSpace.NMath.CoreConnectivityMatrix
      CenterSpace.NMath.CoreNMFConsensusMatrixAlg

Namespace:  CenterSpace.NMath.Core
Assembly:  NMath (in NMath.dll) Version: 7.3
Syntax
public class NMFConsensusMatrix<Alg> : ConnectivityMatrix
where Alg : new(), INMFUpdateAlgorithm

Type Parameters

Alg
Update algorithm for the non-negative matrix factorization.

The NMFConsensusMatrixAlg type exposes the following members.

Constructors
  NameDescription
Public methodNMFConsensusMatrixAlg(DataFrame, Int32, Int32)
Constructs a NFMConsensusMatrix instance from the given data.
Public methodNMFConsensusMatrixAlg(DoubleMatrix, Int32, Int32)
Constructs a NFMConsensusMatrix instance from the given data.
Public methodNMFConsensusMatrixAlg(DataFrame, IEnumerableString, Int32, Int32)
Constructs a NFMConsensusMatrix instance from the given data.
Public methodNMFConsensusMatrixAlg(DataFrame, Int32, Int32, NMFClusteringAlg)
Constructs an NMFConsensusMatrix instance from the given data.
Public methodNMFConsensusMatrixAlg(DoubleMatrix, IEnumerableString, Int32, Int32)
Constructs a NFMConsensusMatrix instance from the given data.
Public methodNMFConsensusMatrixAlg(DoubleMatrix, Int32, Int32, NMFClusteringAlg)
Constructs an NMFConsensusMatrix instance from the given data.
Public methodNMFConsensusMatrixAlg(DataFrame, IEnumerableString, Int32, Int32, NMFClusteringAlg)
Constructs an NMFConsensusMatrix instance from the given data.
Public methodNMFConsensusMatrixAlg(DoubleMatrix, IEnumerableString, Int32, Int32, NMFClusteringAlg)
Constructs an NMFConsensusMatrix instance from the given data.
Top
Properties
  NameDescription
Public propertyCols
Gets the number of columns in the matrix.
(Inherited from DoubleSymmetricMatrix.)
Public propertyDataVector
Gets the data vector referenced by this matrix.
(Inherited from DoubleSymmetricMatrix.)
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 propertyNmf
Gets and sets the NMF clustering object to use.
Public propertyNumberOfConvergedRuns
Gets the number of clustering runs whose NMF computations converged.
Public propertyNumberOfLabels
Gets the number of row/column labels.
(Inherited from ConnectivityMatrix.)
Public propertyOrder
Gets the order of the matrix.
(Inherited from DoubleSymmetricMatrix.)
Public propertyRows
Gets the number of rows in the matrix.
(Inherited from DoubleSymmetricMatrix.)
Top
Methods
  NameDescription
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(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, 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 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 (Inherited from DoubleSymmetricMatrix.)
Public methodCode exampleToString(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
Since the non-negative matrix factorization may not converge to the same solution each time it is run, several runs are made and the average is computed.

For each run of the clustering non-negative matrix factorization a connectivity matrix C with cij = 1 if samples i and j belong to the same cluster and cij = 0 if they belong to different clusters. The consensus matrix is then computed as the average connectivity matrix over several clustering runs. The values of the consensus matrix range in value from 0 to 1 and reflect the probability that samples i and j cluster together.

See Also