DSPRelated.com
Forums

Saving a matlab plot as an image help

Started by jimmy1 March 1, 2010
    Hi everyone, 

 I have a matlab related quetion which can seem simple but it's taking me
ages. I am plotting an x and o over an image and I want to save that image
whith the same size as the original one. This is what I mean:

figure, imshow('data0002.tif'), hold on,
figure,plot(Z{2}(1,:),Z{2}(2,:),'rx',hat_X{2}(1,:),hat_X{2}(3,:),'co')

With this command I manage to do that, the problem is that after that I
want to save that plot as tiff image same size as data0002. I've done that
before using imwrite but this time I am not sure how to do it. I want to
get rid of the white borders that matlab figure creates.
   
     Any help will be appreciated
 
     Jimmy