NMath Reference Guide

## NMFConsensus |

Class NMFConsensusMatrix uses a non-negative matrix factorization to
cluster samples.

Inheritance Hierarchy

SystemObject

CenterSpace.NMath.CoreDoubleSymmetricMatrix

CenterSpace.NMath.CoreConnectivityMatrix

CenterSpace.NMath.CoreNMFConsensusMatrixAlg

CenterSpace.NMath.CoreDoubleSymmetricMatrix

CenterSpace.NMath.CoreConnectivityMatrix

CenterSpace.NMath.CoreNMFConsensusMatrixAlg

Syntax

public class NMFConsensusMatrix<Alg> : ConnectivityMatrix where Alg : new(), INMFUpdateAlgorithm

- Alg
- Update algorithm for the non-negative matrix factorization.

The NMFConsensusMatrixAlg type exposes the following members.

Constructors

Top

Properties

Name | Description | |
---|---|---|

Cols |
Gets the number of columns in the matrix.
(Inherited from DoubleSymmetricMatrix) | |

DataVector |
Gets the data vector referenced by this matrix.
(Inherited from DoubleSymmetricMatrix) | |

Item |
Gets and sets the value at the specified position. Symmetry is maintained.
(Inherited from DoubleSymmetricMatrix) | |

Labels |
Gets and sets the labels for the rows/columns of the connectivity matrix.
(Inherited from ConnectivityMatrix) | |

Nmf | Gets and sets the NMF clustering object to use. | |

NumberOfConvergedRuns | Gets the number of clustering runs whose NMF computations converged. | |

NumberOfLabels |
Gets the number of row/column labels.
(Inherited from ConnectivityMatrix) | |

Order |
Gets the order of the matrix.
(Inherited from DoubleSymmetricMatrix) | |

Rows |
Gets the number of rows in the matrix.
(Inherited from DoubleSymmetricMatrix) |

Methods

Name | Description | |
---|---|---|

Apply(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) | |

Apply(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) | |

Apply(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) | |

Apply(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) | |

Apply(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) | |

Clone |
Constructs a deep copy of self.
(Inherited from ConnectivityMatrix) | |

DeepenThisCopy |
Guarantees that there is only one reference to the underlying
data and that this data is in contiguous storage.
(Inherited from DoubleSymmetricMatrix) | |

Equals |
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) | |

GetHashCode |
Computes hash code.
(Inherited from ConnectivityMatrix) | |

LeadingSubmatrix |
Returns the k by k upper left corner of the matrix. The
matrix and the submatrix share the same data.
(Inherited from DoubleSymmetricMatrix) | |

Resize |
Changes the order of this matrix to that specified, adding zeros or truncating as
necessary.
(Inherited from DoubleSymmetricMatrix) | |

SetLabels |
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) | |

ShallowCopy |
Creates a shallow copy of this matrix.
(Inherited from DoubleSymmetricMatrix) | |

ToCommaSeparated |
Returns a formatted string representation of this matrix using commas
and newlines.
(Inherited from DoubleSymmetricMatrix) | |

ToCommaSeparated(String) |
Returns a formatted string representation of this matrix using commas
and newlines. Numbers are formatted using the specified format string.
(Inherited from DoubleSymmetricMatrix) | |

ToGeneralMatrix |
Converts this sparse matrix to a general matrix.
(Inherited from DoubleSymmetricMatrix) | |

ToString |
Returns a formatted string representation of this matrix.
(Inherited from DoubleSymmetricMatrix) | |

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

ToTabDelimited |
Returns a formatted string representation of this matrix using tabs
and newlines.
(Inherited from DoubleSymmetricMatrix) | |

ToTabDelimited(String) |
Returns a formatted string representation of this matrix using tabs
and newlines. Numbers are formatted using the specified format string.
(Inherited from DoubleSymmetricMatrix) | |

Transform(FuncDouble, Double) |
Modifies the elements of this matrix by applying the given unary function to
each element.
(Inherited from DoubleSymmetricMatrix) | |

Transform(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) | |

Transform(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) | |

Transform(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) | |

Transpose |
Returns this matrix.
(Inherited from DoubleSymmetricMatrix) |

Fields

Name | Description | |
---|---|---|

labels_ |
Lables for the items being connected.
(Inherited from ConnectivityMatrix) |

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