An algorithm for low-dimensional ONMF and multi-component NN-PCA
Matlab
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
matlab
README.md

README.md

spanonmf

An algorithm for low-dimensional Orthogonal Nonnegative Matrix Factorization and multi-component Nonnegative Principal Component Analysis.

The package implements the algorithms of our NIPS 2015 paper Orthogonal NMF through Subspace Exploration.

Requirements

No real requirement, but you may also want to download the textprogressbar and install it in Matlab's path.

Example Usage

%% Nonnegative PCA

% Generate a random data matrix:
m = 10000;
n = 1000;
M = randn(m, n);

% Specify number of components:
k = 5;

W = spannnpcamulti(M, k, ...
                   'verbose', true, ...
                   'approximationrank', 5, ...
                   'numsamples', 1e4);


%% Orthogonal Nonnegative Matrix Factorization

% Generate a random nonnegative data matrix:
m = 100;
n = 1000;
M = rand(m, n);

% Specify target dimension for the approximate factorization:
k = 5;

[W, H, err] = spanonmf(M, k, ...
                       'verbose', true, ...
                       'approximationrank', 5, ...
                       'numsamples', 1e4);