File Exchange

image thumbnail

Normalized Mutual Information

version 1.0 (734 Bytes) by

Fully vectorized implementation NMI. NMI is often used for evaluating clustering results.

4.16667
6 Ratings

43 Downloads

Updated

View License

Normalized mutual information is often used for evaluating clustering results, information retrieval, feature selection etc. This is a optimized implementation of the function which has no for loops.
This function is now a part of the PRML toolbox (http://www.mathworks.com/matlabcentral/fileexchange/55826-pattern-recognition-and-machine-learning-toolbox).

Comments and Ratings (13)

Albert Pun

Would appreciate more comments and some examples

Hi,
I am trying to find similarities between two signals obtained from two different modalities and sampling frequencies.Hence tried the mutual information code. but i get an error : 'Error using sparse
Sparse matrix sizes must be non-negative integers less than MAXSIZE as defined by COMPUTER. Use HELP COMPUTER for more details.

Error in nmi (line 20)
Mx = sparse(idx,x,1,n,k,n);'

Please help me correct this error.

samira rahimi

Ori

Ori (view profile)

Hello,
Why is it important to verify the integrity of results, i.e. length(labels)==length(results)?

Isn't it possible to use nmi for clustering with k that is different from number of labels?

I changed the script for my use so that it will accept this. should I upload?

please add more comments, especially for the inputs. Thanks

bao dinh

a

Kelvin Wong

It doesn't work for large matrix as it rans out of memory in line 16 and 17.

yang

yang (view profile)

Eric Chen

grateful if more comments provided

Good job, I used your function to validate mine :). Sometime in research you cannot trust even yourself.

Can you give a detailed docomented .m file so that we can have a easy understanding of NMI.

Thanks
Ali

NR P

NR P (view profile)

I agree, an example... and a little description of the inputs would be strongly appreciated! Thank you!

Zhi

Zhi (view profile)

Could you provide some examples of running your code to prove it is correct?

Updates

1.0

minor tweak

MATLAB Release
MATLAB 9.0 (R2016a)

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video

nmi/