MATLAB: How to write a function which gives me entropy using discrete probability distribution as input.thanks in advance

entropy

here is the entropy Formula for discrete probability distribution

Best Answer

entropy = @(P) -sum(P.*log2(P))