I have recently been trying to create a custom-sized graph in MATLAB and save it automatically using the saveas function. I am having issues saving the files in the size that I create them.
Roughly speaking, my code is as follows:
mygraph = figure('Position',[1,20,1280,1024]);
So far, the code above can create a custom-sized graph on my screen, but it seems to save the pictures in a default size. The weird thing is that if I do not use the saveas function and save the figure manually, then the image retains its size.
For clarification purposes, I'm currently saving the graphs as emf, though I'm also open to using jpg/png/bmp if works fine too.