I am using the code currently given at http://www.quuxlabs.com/blog
This gives a good result. And I clearly see what changes in the matrix have occurred.
I also tried using the sklearn library at sklearn.decomposition.NMF But the results that I got with the same input are not good enough. Maybe I missed something.
Here is my sample code -
from sklearn.decomposition import NMF , ProjectedGradientNMF R = [ [5,3,0,1], [4,0,0,1], [1,1,0,5], [1,0,0,4], [0,1,5,4], ] R = numpy.array(R) nmf = NMF(beta=0.001, eta=0.0001, init='random', max_iter=2000,nls_max_iter=20000, random_state=0, sparseness=None,tol=0.001) nR = nmf.fit_transform(R) print nR print print nmf.reconstruction_err_ print
It does not support output / populated values ββin the matrix, as I can see, using the code provided on the blog.
Can someone help me understand!