Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Re; Stata graphs exported to pdf in Adobe

From   Kit Baum <[email protected]>
To   [email protected]
Subject   st: Re; Stata graphs exported to pdf in Adobe
Date   Sat, 26 Mar 2005 10:34:53 -0500

Erik said
I have, for a long time, relied on exporting graphs from Stata as .eps
files and then use "epstopdf" (from GhostScrip, I think) to convert the
resulting eps-files to pdf-files, and then including the pdf-files in
pdfLaTeX documents. Now this seems to fail. The pdf-files give a
109-error in Adobe products (PhotoShop 7, the latest Reader and Acrobat
5 on MacOsX). It looks ok in "preview" on macosx and prints ok from my

This is an examples of a problematic file:

Indeed, that file is problematic in Acrobat 5.0 (full version) in Mac OS X, while Preview is happy with it. What happens if you produce the .gph and then

graph export vys.pdf, replace

without the intermediate step of eps->pdf? That might be where the problem is being introduced (i.e. Stata is writing good .eps files, but Ghostscript is munging them). I do not use GS, so I cannot test that hypothesis.

However please note that you do not have to create PDF to easily include graphs in pdfLaTeX documents. The preferred method, for instance, for the Stata Journal style is to include as .eps with code like

\caption{{\tt graph matrix} of regression variables.}

This works fine with TeXShop for Mac OS X, and gives greater control over the placement of figures.

Kit Baum, Boston College Economics

* For searches and help try:

© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index