This preview shows page 1. Sign up to view the full content.
Unformatted text preview: sum=0; for i=1:length(count), sum=sum+count(i); end prob=count./sum; zero_entropy=0; for i=1:length(prob), if prob(i)~=0 zero_entropy=zero_entropy-(prob(i)*log2(prob(i))); end end zero_entropy...
View Full Document
This homework help was uploaded on 04/05/2008 for the course EE/CPE 462 taught by Professor Prof.hongman during the Spring '07 term at Stevens.
- Spring '07