MATLAB: How to size a figure I export in .bmp

bmpexportfigureplotsaveassize;

Hi,
I would like to change the size of a graph which I export into a .bmp format. My code, for the figure, is :
figure(1)
plot(V1pu,'DisplayName','V1pu')
set(gcf, 'PaperUnits', 'points');
set(gcf, 'PaperSize', [500 1000]);
set(gcf, 'PaperPosition', [0 0 500 1000]);
saveas(gcf,['C:\Users\Philippe\VA.bmp'],'bmp');
When I run this code, the export size is 560×420 pixels, whatever I try. I would like a .bmp of 500 by 1000 pixels. Any idea what I did wrong?
Thank you for you time.

Best Answer

Consider using print which specifically supports figure paper properties; you might also want to change the print -r (resolution) option.