hi buddies
i am in an emergency situation , i must divide an image into some image with same size as original one in matlab without using for loop!
could anyone help me?
here is the code i used but didn't work...
imagepath='forest.tif'
[I map]=imread(imagepath);
Ig=I;
if ~isempty(map)
Ig=ind2gray(I,map);
elseif length(size(I))==3
Ig=RGB2gray(I);
else
Ig=I;
end;
I1=I<100;
I2=100=< I<160;
I3=I>=160;
imshow(I2)
i am in an emergency situation , i must divide an image into some image with same size as original one in matlab without using for loop!
could anyone help me?
here is the code i used but didn't work...
imagepath='forest.tif'
[I map]=imread(imagepath);
Ig=I;
if ~isempty(map)
Ig=ind2gray(I,map);
elseif length(size(I))==3
Ig=RGB2gray(I);
else
Ig=I;
end;
I1=I<100;
I2=100=< I<160;
I3=I>=160;
imshow(I2)