> However, when I use manual size (wfactor, hfactor above) Matlab adds a white > margin to the document at the left and right side. I would like to remove > those margins because I need the plots to align with the text in the > documents.
What exactly do you want to align with your text? The y axis label, the tick descriptors, the ticks, the y axis? Please give some more details.
Matlab's eps output is far from perfect. I usually hack the eps files to remove things I don't want, like the background rectangle.
Matlab adds a white filled rectangle as figure back- ground object to the eps file. You can see that when you import the eps file into a vector graphics program and ungroup the imported object. In the eps file, the line responsible is
0 0 <x> <y> rf
<x> and <y> are numbers that depend on the PaperPosition property of the figure. rf produces the filled rectangle.
Comment this line out if you want to get rid of the figure background rectangle. Using set(gcf,'Color','none') doesn't work, contrary to my exspectation.
The upcoming Matlab 7.0 will have new axis properties to help better control bounding boxes, see http://tinyurl.com/2j8kx