Hi,

----- Original Message -----
From: "Andrew Criswell" <[EMAIL PROTECTED]>
To: "r-help" <[EMAIL PROTECTED]>
Sent: Friday, August 22, 2003 2:17 AM
Subject: [R] Getting graphs into LaTeX


> Hello ALL:
>
> I ran with success the following commands in R getting a file saved
> --------------------------------------------------------------------------
----------
> postscript()
>
> postscript('~/data/st202/2003/lecture00/lecture00-graph-01.eps',
>            horizontal = FALSE, height = 6, pointsize = 10)
>
> hist(trial.outcome.5, breaks = 5,
>      main = '1000 Replications of 5 Trials of a Coin Toss',
>      xlab = 'Frequency of a Tail')
> --------------------------------------------------------------------------
----------


Have you closed the postscript device?  Normally you need a dev.off() after
you finished the plot.  Try putting dev.off() after your hist().

The other thing is can you actually view "lecture00-graph-01.eps" in the
directory, with a postscript Viewer?

The last point, I think pdflatex (or pdftex) does not accept PS/EPS
formatted picture.  Can you latex trix.tex?  If so, try to save your
histogram as a PDF or PNG file, then pdflatex it again.

Cheers,

Kevin

------------------------------------------------
Ko-Kang Kevin Wang
Master of Science (MSc) Student
Department of Statistics
University of Auckland
New Zealand
www.stat.auckland.ac.nz/~kwan022



********************************************

______________________________________________
[EMAIL PROTECTED] mailing list
http://www.stat.math.ethz.ch/mailman/listinfo/r-help

Reply via email to