I use matlab in order to generate plots in pdf files. These plots in pdf should have correct sized therefore I use PaperSize. Then I have to position plot with correct PaperPosition. The problem is that matlab uses some strange equation in order to calculate position of the plot on the page. So plot positioning is constant shooting with parameters instead of calculating it. For example:
set(gcf, 'PaperPosition', [-0.3 -0 7.2 3.1]); %Position the plot further to the left and down. Extend the plot to fill entire paper.[left bottom width height]
set(gcf, 'PaperSize', [6.5 3]); %Keep the paper size [width height]
Do you know how matlab calculates this position ?