[R] R Graphics: Saving PDF and other formats from Windows Graphic Device for LaTeX

Stefan Grosse singularitaet at gmx.net
Thu Oct 5 09:41:06 CEST 2006


> pdf("sgr6100.pdf", horizontal=FALSE, onefile=FALSE, 
> height=3, width=3, pointsize=6)
>
> Reducing point-size below 6 does not seem to make any difference to 
> the size of text and symbols. Any suggestions to get smaller font sizes?
>   

I have never used the pointsize option. Increasing the height and the
width decreases the relative size of the font so if you scale down the
figure in LaTeX you would get smaller fonts.

> I am using WinEdt with MikTeX set-up. 
>   

as well do I ...



> Latex complains about the [scale...] part for any scale in 
>
> \includegraphics[scale=1]{} 
>   

A scale of one does not make any sense since it is 100% or with other
words you could leave that out.

If you want to scale the figure to the text width you could write
\begin{figure}
\includegraphic[width=\textwidth]{sgr6100.pdf }
\end{figure}

btw. I use the postscript device to produce an eps file and dvipdfm to
convert the dvi to pdf

postscript("sgr6100.eps", width = 6, height = 6, horizontal = FALSE,
onefile =T, paper="special")

and then in LaTeX:

\begin{figure}
\includegraphic[width=\textwidth]{sgr6100}
\end{figure}



> and pauses. Suggestions will be appreciated about what is the best way to scale
> R graphics for inclusion in LaTeX.
>
>   
see above.

Have a look at a good LaTeX guide like lshort
http://tobi.oetiker.ch/lshort/lshort.pdf
(e.g. p.73/73)

Stefan Grosse



More information about the R-help mailing list