0
function im = Thresholding(I)
[r,c] = size(I);
im = zeros(r, c);
for i = 1:r
for j = 1:c
    if I(i,j)> 105
        im(i,j) = 1;
    end
end
end
im = bwareopen(im, 5);
im = imfill(im, 'holes');
end 

I'm trying to use this code and I got this error " Undefined function or method 'bwareopen' for input arguments of type 'double'"please help me

  • It seems that the program doesn't recognize it. Are you sure you have the proper version that contains a definition of the function? – Leb Oct 04 '15 at 02:30
  • im use matlab R2010b which version that available with that function. i need to finish my final year project for handwriting recognition. im glad if you can hel me. thanks you – user5405704 Oct 04 '15 at 02:41
  • You made an error copying your code here. It contains an invalid character (`). – Daniel Oct 04 '15 at 09:33
  • @Daniel i've been edit my code. im really a newbie in image processing. can you help me solve this problem of thresholding? – user5405704 Oct 04 '15 at 13:59

1 Answers1

3

You're calling bwareopen but you should be calling bwareaopen. The latter has an extra a.

Clarissa G
  • 341
  • 1
  • 8