[R] a question about "latex" in Hmisc

Ista Zahn istazahn at gmail.com
Wed May 12 22:23:55 CEST 2010


On Wednesday 12 May 2010 3:58:08 pm Shi, Tao wrote:
> Erik,  No, you didn't misunderstand my question.
> 
> 
> Ista,
> 
> I have no access to LaTex now, so I can't test your solution right away. 
> My understanding to your solution is that, basically, you just let 'latex'
> function generate the tex text which is directly incorporated into the big
> .tex file (rather a separate .tex file just for that table).  Am I right?

Yes, that is correct. As far as I'm aware the print method for latex() 
actually typesets the table. To avoid this, simply set file="" as I suggested.

If you would rather have a separate file for your table you can continue to 
use your original method, e.g., 
<<>>=
tmp <- latex(x, file="x.tex")
@
\include{x.tex}

(not sure what your objection to this was in the first place).

-Ista
> 
> Thanks,
> 
> ...Tao
> 
> 
> 
> 
> 
> ----- Original Message ----
> 
> > From: Erik Iverson <eriki at ccbr.umn.edu>
> > To: Ista Zahn <istazahn at gmail.com>
> > Cc: r-help at r-project.org
> > Sent: Wed, May 12, 2010 12:34:15 PM
> > Subject: Re: [R] a question about "latex" in Hmisc
> 
> Ista Zahn wrote:
> > Hi Tao,
> > I think you just need latex(x,
> > file="")
> 
> I think I misunderstood the question, I believe that is
> 
> > what is needed here.
> 
> ______________________________________________
> 
> > ymailto="mailto:R-help at r-project.org"
> > href="mailto:R-help at r-project.org">R-help at r-project.org mailing list
> > 
> > href="https://stat.ethz.ch/mailman/listinfo/r-help" target=_blank
> > 
> > >https://stat.ethz.ch/mailman/listinfo/r-help
> 
> PLEASE do read the posting
> 
> > guide http://www.R-project.org/posting-guide.html
> 
> and provide commented,
> 
> > minimal, self-contained, reproducible code.



More information about the R-help mailing list