spectralNMF | R Documentation |
Perform Non-Negative Matrix factorization on spectral data
spectralNMF( object, rank, method = "PGNMF", initSpectralData = NULL, nruns = 10, subsamplingFactor = 1, checkDivergence = TRUE, maxIter = 1000, includeRefs = FALSE )
object |
|
rank |
number of NMF components to be found |
method |
name of the NMF method to be used. "PGNMF" (default), "HALSacc" and "semiNMF" are methods derived from the hNMF package. All methods from the NMF package are also available. |
initSpectralData |
this can be a list of spectralData objects, containing the pure component spectra. It can also be either of the NMF factor matrices with initial values |
nruns |
number of NMF runs. It is recommended to run the NMF analyses multiple times when random seeding is used, to avoid a suboptimal solution |
subsamplingFactor |
subsampling factor used during NMF analysis |
checkDivergence |
Boolean indicating whether divergence checking should be performed |
maxIter |
maximum number of iterations per NMF run |
includeRefs |
boolean, indicating whether references should be included in the input matrix for the NMF analysis |
SpectraInTimeComp-class
which includeds a scaled NMF model (in accordance with the NMF package definition)
SpectraInTimeComp-class
Nicolas Sauwen
spectralExample <- getSpectraInTimeExample() nmfResult <- spectralNMF( spectralExample , rank = 2 , subsamplingFactor = 5 ) nmfObject <- getDimensionReduction( nmfResult , type = "NMF")$NMF nmfTrends <- t( NMF::coef( nmfObject ) ) matplot( nmfTrends , type = "l" , x = getTimePoints( spectralExample , timeUnit = "hours" ), xlab = "time in hours" )
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.