Skip to content

Latest commit

 

History

History
31 lines (19 loc) · 1.05 KB

File metadata and controls

31 lines (19 loc) · 1.05 KB

Non-negative Matrix Factorization

Build Status

A Julia package for Non-negative Matrix Factorization based on the method introduced by Lee and Seung and compliant with the MLJ model interface.

Using the Package

To train an NMF model, first load MLJ and this package

using MLJ, MLJNonnegativeMatrixFactorization

The NMF can then be instantiated in the usual way for an unsupervised model:

nmf = NMF()
mach = machine(nmf, df)
fit!(mach)

Calling fitted_params on the trained machine will return a tuple containing the factor matrix (a.k.a. endmembers) W and the factor loading matrix (a.k.a. abundances) H.

The NMF can be used for feature extraction via W or for dimensionality reduction to the factor loadings via

= MLJ.transform(mach, X)