Hi all,
I use Matlab to make a lot of figures for my reports.
I'd like to be able to print the figures in a way so that there is a 1:1 ratio between what I display and the saved picture (the -r0 improves the results but I don't get exactly the same results I set using the 'OuterPosition' value).
Also I would like to know if there is a way to save pictures without the "white" border.
More relevantly I would like to know if I can make this behaviour to be the default for matlab, that is to save the default settings to apply to all the figures (like default linewidth, size, resolution on print and so on. So that I won't have to rewrite long command to display (and print) figure properly (I usually save figures using: print([fileName '.png'], '-r0','-dpng')
Any advice is well accepted!
Thanks to all of you for your help.
I'm sorry if I won't answer promptly but I'll be out for some days and might not be able to read the answers!!!
Cheers, -Luca
|
|
0
|
|
|
|
Reply
|
Luca
|
7/8/2010 4:12:24 PM |
|
"Luca Cerone" wrote:
> Hi all,
> I use Matlab to make a lot of figures for my reports.
> I'd like to be able to print the figures in a way so that there is a 1:1 ratio between what I display and the saved picture (the -r0 improves the results but I don't get exactly the same results I set using the 'OuterPosition' value).
> Also I would like to know if there is a way to save pictures without the "white" border.
> More relevantly I would like to know if I can make this behaviour to be the default for matlab, that is to save the default settings to apply to all the figures (like default linewidth, size, resolution on print and so on. So that I won't have to rewrite long command to display (and print) figure properly (I usually save figures using: print([fileName '.png'], '-r0','-dpng')
> Any advice is well accepted!
> Thanks to all of you for your help.
> I'm sorry if I won't answer promptly but I'll be out for some days and might not be able to read the answers!!!
> Cheers, -Luca
getframe does a screen grab of the figure, so you get exactly what is on screen.
set(gcf, 'PaperPositionMode', 'auto') makes print export to the same dimensions as the on screen figure.
Cropping is easy to do in code. However, export_fig (http://www.mathworks.com/matlabcentral/fileexchange/23629-exportfig), will do it for you, and does other nice things, like anti-aliasing, too.
HTH,
Oliver
|
|
0
|
|
|
|
Reply
|
Oliver
|
7/9/2010 10:09:06 AM
|
|
Luca:
I also recommend export_fig. There are always so many problems when you try to use the canned MATLAB functions, as you and many others have learned. Why not take advantage of someone who's been through all that pain and figured out a better way of doing it?
|
|
0
|
|
|
|
Reply
|
Image
|
7/9/2010 11:25:05 AM
|
|
Thanks for the advice guys,
sorry for the delay but I was out of my office.
I'll have a look at export_fig.
Also, maybe you know how to choose the right font size so that it
looks good when printed?
I can get readable fonts on screen, but when I reduce to the dimension
to use in the report they simply are too small.
Thanks a lot in advance.
Cheers, -Luca
"Image Analyst" <imageanalyst@mailinator.com> wrote in message <i170uh$jj5$1@fred.mathworks.com>...
> Luca:
> I also recommend export_fig. There are always so many problems when you try to use the canned MATLAB functions, as you and many others have learned. Why not take advantage of someone who's been through all that pain and figured out a better way of doing it?
|
|
0
|
|
|
|
Reply
|
Luca
|
7/14/2010 3:09:04 PM
|
|
|
3 Replies
202 Views
(page loaded in 0.044 seconds)
Similiar Articles: command-line printing of figure: how to resize/rescale figure for ...... file2.png - print the files the other way around - don't print ... ext function that makes a plot in a figure/gcf then I set the size of the plot as desired and print ... How to save a figure without displaying ? - comp.soft-sys.matlab ...... popup window that interrupts any other ... How to reduce a PDF figure size? - comp.text.pdf How to save a figure without ... fig file, when double clicked ... Print figure or ... opengl save as jpeg - comp.soft-sys.matlab... comp.lang.awk... jpeg size - comp.soft-sys.matlab I want to print a Matlab figure to a fixed size ... able to do it manually, and save it as a TGA image. But I think other ... avifile getframe screensaver problems - comp.soft-sys.matlab ...... the results, in terms of the file size and image quality. However, if I do other ... print() and imread() are very slow (I ... simple to set the renderer for my figure ... Plotting Matlab figures on the Server - comp.soft-sys.matlab ...... colored triangle (smoothly interpolated) Other ... Matlab figure to fixed jpeg size - comp.soft-sys.matlab I want to print a Matlab figure to a fixed size jpeg file ... print setup saves the printer - comp.databases.filemaker ...... HP DeskJet 7960 is different than the print area for the same page size ... cheers, > Dave we have the probs of other ... Print figure or save to file - MATLAB - MathWorks ... reducing size of desktop photos - comp.sys.mac.apps... center" "full screen" or any other option the size of ... help setting up multiple page print ... how to expand page size? - comp.text.pdf How to reduce a PDF figure size? - comp ... DCPS v2.7 problem with HP P2055dn printer - comp.os.vmsOn the other hand, I have seen no problems ... True, some magic part of the printer figures out how you want your job to print. ... in DCPS, unlike values for Paper Size or ... File size difference, InDesign vs Distiller - comp.text.pdf ...For print, I distill ps to pdf, and the web version is ... http://www.stuk.fi/test/> Regarding accessibility issues ... is a prerequisite for many screen readers and other ... Solaris 10 printer problems - comp.unix.solarisOr is there some > >other way to get the ppd to work? > > You shouldn't need to configure the printer via the JDS tools to print > from ... Can't figure it out. I probably ... Print figures size and other issues - Newsreader - MATLAB CentralHi all, I use Matlab to make a lot of figures for my reports. I'd like to be able to print the figures in a way so that there is a 1:1 ratio between what I display ... Print figure or save to file - MATLAB - MathWorks - MATLAB and ...Specifying any other graphics ... print('-s') For information about issues specific to printing ... enables you to resize the figure window and print it at the size ... 7/16/2012 3:04:14 AM
|