public class LocalityPreservingProjection extends Object
SR_caller.m
, SR.m
, lsqr2.m
, and lars.m
.
This class requires the availability of Matlab or Octave.
Each of the projection methods requires the prior calculation of the
affinity matrix. This matrix identifies which rows in the input matrix have
some degree of local proximity. A non-zero value in the affinity matrix
specifies the weight of the connection between the two rows. Weights may be
of any positive value. See AffinityMatrixCreator
for programatic
ways of creating an affinity matrix based on similarity methods.
SVD
,
AffinityMatrixCreator
Modifier and Type | Method and Description |
---|---|
static MatrixFile |
project(MatrixFile inputMatrix,
MatrixFile affinityMatrix,
int dimensions)
Projects the rows of the input matrix into a lower dimensional subspace
using the Locality Preserving Projection (LPP) algorithm and the affinity
matrix as a guide to locality.
|
static Matrix |
project(Matrix m,
MatrixFile affinityMatrix,
int dimensions)
Projects the rows of the input matrix into a lower dimensional subspace
using the Locality Preserving Projection (LPP) algorithm and the affinity
matrix as a guide to locality.
|
static Matrix |
project(Matrix m,
Matrix affinityMatrix,
int dimensions)
Projects the rows of the input matrix into a lower dimensional subspace
using the Locality Preserving Projection (LPP) algorithm and the affinity
matrix as a guide to locality.
|
public static MatrixFile project(MatrixFile inputMatrix, MatrixFile affinityMatrix, int dimensions)
inputMatrix
- a matrix file whose rows will be projectedaffinityMatrix
- a square matrix whose entries denote locality
between the rows of the inputMatrix. Note that this matrix's
dimensions must be equal to the number of rows in the input
matrix.dimensions
- the number of dimensions into which the inputMatrix
should be projectedDENSE_TEXT
format.IOError
- if any exception occurrs during processingpublic static Matrix project(Matrix m, MatrixFile affinityMatrix, int dimensions)
m
- a matrix whose rows will be projectedaffinityMatrix
- a square matrix whose entries denote locality
between the rows of the inputMatrix. Note that this matrix's
dimensions must be equal to the number of rows in the input
matrix.dimensions
- the number of dimensions into which the inputMatrix
should be projectedMatrix
that contains the rows of m
projected
into the specified number of dimensionsIOError
- if any exception occurrs during processingpublic static Matrix project(Matrix m, Matrix affinityMatrix, int dimensions)
m
- a matrix whose rows will be projectedaffinityMatrix
- a square matrix whose entries denote locality
between the rows of the inputMatrix. Note that this matrix's
dimensions must be equal to the number of rows in the input
matrix.dimensions
- the number of dimensions into which the inputMatrix
should be projectedMatrix
that contains the rows of m
projected
into the specified number of dimensionsIOError
- if any exception occurrs during processingCopyright © 2012. All Rights Reserved.