[R] Hmisc - latex - table.env not observed
    Frank E Harrell Jr 
    f.harrell at vanderbilt.edu
       
    Sun Dec 24 06:34:18 CET 2006
    
    
  
steve wrote:
> The following code
> 
> library(Hmisc)
> x = 1:10
> y = x
> latex(summary(x~y),table.env=FALSE)
> latex(summary(cbind(x,y)),table.env=FALSE)
> 
> should produce latex output that is not a table. The second  one 
> produces just a tabular, as it should. However, the first one produces a 
> tabular embedded in a table. (This is the effect if you leave 
> table.env=FALSE out).
summary(x~y) produces a summary.formula.response object and 
latex.summary.formula.response generates a caption for the table. 
Whenever latex.default sees a caption it sets table.env to TRUE.
You might try the ctable option if you have the ctable style installed 
in LaTeX or we can think about respecting table.env more fully.  But I 
wouldn't know what to do with the caption then.
-- 
Frank E Harrell Jr   Professor and Chair           School of Medicine
                      Department of Biostatistics   Vanderbilt University
    
    
More information about the R-help
mailing list