lsNMF-nmf: Multiplicative Updates for LS-NMF

nmf_update.lsnmfR Documentation

Multiplicative Updates for LS-NMF


Implementation of the updates for the LS-NMF algorithm from Wang et al. (2006).

wrss implements the objective function used by the LS-NMF algorithm.


  nmf_update.lsnmf(i, X, object, weight, eps = 10^-9, ...)

  wrss(object, X, weight)

  nmfAlgorithm.lsNMF(..., .stop = NULL,
    maxIter = nmf.getOption("maxIter") %||% 2000, weight,
    eps = 10^-9, = .Machine$double.eps,
    check.interval = 5 * check.niter, check.niter = 10L)



current iteration


target matrix


current NMF model


value for \Sigma, i.e. the weights that are applied to each entry in X by X * weight (= entry wise product). Weights are usually specified as a matrix of the same dimension as X (e.g. uncertainty estimates for each measurement), but may also be passed as a vector, in which case the standard rules for entry wise product between matrices and vectors apply (e.g. recylcing elements).


small number passed to the standard euclidean-based NMF updates (see nmf_update.euclidean).


extra arguments (not used)


specification of a stopping criterion, that is used instead of the one associated to the NMF algorithm. It may be specified as:

  • the access key of a registered stopping criterion;

  • a single integer that specifies the exact number of iterations to perform, which will be honoured unless a lower value is explicitly passed in argument maxIter.

  • a single numeric value that specifies the stationnarity threshold for the objective function, used in with nmf.stop.stationary;

  • a function with signature (object="NMFStrategy", i="integer", y="matrix", x="NMF", ...), where object is the NMFStrategy object that describes the algorithm being run, i is the current iteration, y is the target matrix and x is the current value of the NMF model.


maximum number of iterations to perform.

maximum absolute value of the gradient, for the objective function to be considered stationary.


interval (in number of iterations) on which the stopping criterion is computed.


number of successive iteration used to compute the stationnary criterion.


updated object object


Wang G, Kossenkov AV and Ochs MF (2006). "LS-NMF: a modified non-negative matrix factorization algorithm utilizing uncertainty estimates." _BMC bioinformatics_, *7*, pp. 175. ISSN 1471-2105, <URL:>, <URL:>.

NMF documentation built on March 31, 2023, 6:55 p.m.