Re: Left censoring problem using S+

Erin Hodgess (hodgess@uhdux2.dt.uh.edu)
Fri, 23 Jan 1998 17:21:47 -0600


From: kjetil halvorsen <kjetil@caoba.entelnet.bo>
X-Mailer: Mozilla 3.01 (Win95; I)
Mime-Version: 1.0
To: s-news@utstat.toronto.edu
Subject: S-Plus graphs to LaTeX picture commands
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Status: R

Kjetil Halvorsen writes:

Is there any possibility to write code which ``translates''
from splus graphics to latex picture commands? Or somebody
has written something like that?

I did some of that for xlispstat, but cannot see how to do it for
splus.

Kjetil Halvorsen.
Here is a somewhat old, but useful suggestion:
You need a sty file called psfig.sty. I will
send that directly to Kjetil. If anyone else wants
that file, please let me know!

Now you can create a sample.

Here is a sample Latex File:

\documentstyle[12pt,psfig]{article}
\oddsidemargin -0.07in
\evensidemargin -0.04in
\topmargin -0.13in
\textheight = 8.4in
\textwidth = 6.5in
\pagestyle{empty}
\begin{document}

\baselineskip = 22pt

\centerline{The test of postscript}
\centerline{\psfig{figure=corn1.ps,width=4in,height=3in}}

\end{document}

To create the corn1.ps file in S-Plus:
> postscript("corn1.ps")
> plot(corn.rain,corn.yield,type="l")
> q()

Then try it out!

Good Luck!

Sincerely,
Erin Hodgess
Assistant Professor
Dept. of Computer and Mathematical Sciences
University of Houston -- Downtown
e-mail: hodgess@uhdux2.dt.uh.edu