I have a binary image in a matrix, call it binarymage. I then want to determine whether various areas in the image are white pixels only. The boundaries for the areas of interest are defined in as follows:
left=; right=; top=[5,6,7,8]; bottom=[15,16,17,18];
So in this example I have 4 boxes. How can get a result that tells me which boxes are white only. Example: whiteboxes=[1,0,1,0].
I think I need arrayfun but have not been successful after several attempts. Appreciate any help please. Thank you.