Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

saving multiple figures in one pdf

1,316 views
Skip to first unread message

moll

unread,
Apr 7, 2008, 10:04:31 AM4/7/08
to
Hello,
i know one can save one figure as an pdf-file, but is there also the
possibility to append figures to an existing pdf file or any other way
to create an multi-page pdf document with multiple figures?
Thanks in Advance

mv20100

unread,
Apr 7, 2008, 10:51:41 AM4/7/08
to
If you own Adobe Illustrator you can save each figure into separate ".ai" files with Matlab, then with Illustrator bring them into one file and do your own arrangement. You can also add comments, drawings, arrows or anything else.
".ai" files preserve the quality.

moll

unread,
Apr 8, 2008, 8:41:32 AM4/8/08
to
At the moment I save each figure in one pdf and join them later with
Adobe Acrobat (Document -> Insert pages), but neither mine or your
variant is an suitable workaround (IMHO).

Alex Knight

unread,
Apr 8, 2008, 10:00:32 AM4/8/08
to
moll <na...@pik-potsdam.de> wrote in message
<65unvfF...@mid.dfncis.de>...

One easy way is to print multiple figures to one postscript
file. For all except the first figure, use the '-append'
option.

Then convert the postscript file to a PDF using Adobe
Distiller (if you have Adobe Acrobat this is included).

You can automate the whole thing using a script. For
example:

psname = 'example.ps';
print ( '-dpsc2', psname, '-f1' )
print ( '-dpsc2', psname, '-append', '-f2' )
winopen ( psname );

If distiller is installed winopen will bring the file up in
Distiller - also works with Ghostscript I believe. Hope
that helps!

Alex

The views expressed in this site are those of the
originator and do not necessarily represent the views of
NPL Management Ltd. Nothing in this post shall bind NPL
Management Ltd in any contract or obligation.


Richard Quist

unread,
Apr 9, 2008, 11:18:46 AM4/9/08
to
I just uploaded a utility to the File Exchange to make it easier to do this
with multi-page postscript files. Take a look at ps2pdf available from here
http://www.mathworks.com/matlabcentral/fileexchange/loadAuthor.do?objectId=1097474&objectType=author
--

Richard Quist
Software Developer
The MathWorks, Inc.

moll

unread,
Apr 16, 2008, 8:29:35 AM4/16/08
to
Hi Richard,
thank you very much for the file, it works perfectly.
A nice supplementary feature would be an optional parameter for deleting
the .ps file.
TIA


Richard Quist wrote:
> Alex Knight wrote:
>> moll <na...@pik-potsdam.de> wrote in message
>>

Richard Quist

unread,
Apr 18, 2008, 8:14:55 AM4/18/08
to
Thanks for the feedback.

I just uploaded an update to allow for deletion of the input postscript file
by specifying an optional 'deletepsfile' parameter with a non-zero value to
delete the file and a value of 0 to keep the file. If the parameter is not
specified the default is to NOT delete the file

0 new messages