for the code-
A=imread('xyz.jpg');A1=rgb2gray(A);A = A1(:);[symbols,p]=hist(A,double(unique(A)))p=p/sum(p)symbols=symbols/sum(symbols)[dict,avglen]=huffmandict(symbols,p)comp=huffmanenco(A,dict)
i am getting error-
Error using huffmandict (line 164)Source symbols repeatError in new (line 7)[dict,avglen]=huffmandict(symbols,p)
suggest necessary changes
Best Answer