| nmfkc.ard | R Documentation |
Prototype of Tan & Fevotte's (2013) ARD-NMF (Euclidean /
\beta = 2). Unlike the cross-validation (nmfkc.ecv,
nmfkc.bicv) and stability (nmfkc.consensus)
engines that scan a range of ranks, ARD fits NMF once at
an over-complete rank and prunes automatically: each component k
carries a relevance weight \lambda_k with an inverse-gamma prior;
the multiplicative updates gain a penalty + w_{fk}/\lambda_k (L2 /
half-normal prior) or + 1/\lambda_k (L1 / exponential), which
drives unsupported components to zero. The number of surviving
components is the estimated rank. Covariates are ignored (plain NMF).
This is a model-based point estimate: the result depends on the prior, the starting rank and the random initialization, and can vary run to run. Use it as a complement to the CV / consensus engines, not a sole criterion.
nmfkc.ard(Y, rank = NULL, nrun = 10, plot = FALSE, ...)
Y |
Observation matrix ( |
rank |
Over-complete starting rank |
nrun |
Number of random-initialization restarts (default |
plot |
Logical; draw the relevance bar plot. |
... |
Advanced options, rarely needed (defaults in parentheses):
|
Relation to Tan & Fevotte (2013). The update equations reproduce
the paper's \ell_2 / \ell_1 ARD-NMF for the Euclidean
(\beta = 2) case exactly: the multiplicative penalties, the
closed-form \lambda_k update (f(w_k) + f(h_k) + b)/c and the
constant c (their Eq. 33). Two deliberate simplifications keep it
practical: only \beta = 2 is implemented (the paper covers the general
\beta-divergence), and the default b is an empirical
per-component energy scale (F + N)/K \cdot \bar{Y} that reliably avoids
the winner-take-all collapse, rather than the paper's method-of-moments value
(their Eq. 38).
An object of class "nmfkc.ard": a list with
rank (estimated = mode over restarts), rank.runs (the
per-run estimates), relevance (representative run, descending),
lambda, W, H (ordered by relevance),
rank.init, prior, nrun, objfunc (final
objective value of the representative run) and objfunc.iter (its
per-iteration trajectory).
V. Y. F. Tan and C. Fevotte (2013). Automatic relevance determination in nonnegative matrix factorization with the beta-divergence. IEEE TPAMI 35(7):1592–1605. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1109/TPAMI.2012.240")}.
nmfkc.ecv, nmfkc.bicv,
nmfkc.consensus, nmfkc.rank
set.seed(1)
X <- matrix(abs(rnorm(40 * 3)), 40, 3)
B <- matrix(abs(rnorm(3 * 60)), 3, 60)
ar <- nmfkc.ard(X %*% B, rank = 10) # over-complete start
ar$rank # ~ 3 surviving components
plot(ar)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.