3
votes

I loaded a gray scale image to Matlab to perform the quantization. Unfortunately the output is nothing.

I = imread('asa.jpg');
imshow(I)
axis off
title('Grayscale Image')
thresh = multithresh(I,7);
valuesMax = [thresh max(I(:))]
[quant8_I_max, index] = imquantize(I,thresh,valuesMax);
valuesMin = [min(I(:)) thresh]
quant8_I_min = valuesMin(index);
imshowpair(quant8_I_min,quant8_I_max,'montage')
title('Minimum Interval Value           Maximum Interval Value')
1
try imshowpair(quant8_I_min,quant8_I_max,'montage','scaling',''independent'')Ander Biguri
@AnderBiguri I tried, but I still get a blank screen. What might be the issue?AsankaD7

1 Answers

1
votes

I believe there is a problem with the image. I tried your code, and it seems to work...

enter image description here

Can you please show a screen shot to explain better what the issue is? You should also include your Matlab version number in the question.