On 07/15/04 11:07, [EMAIL PROTECTED] wrote:
>Hi,
>
>I use the excellent Sweave tools for writing documents
>but was wondering how to neatly print a data.frame
>with long column headings.
>I cant manage to do this via package:xtable.
I think a problem with xtable is this:
> xtable(d1,align=c("|l|","c","c","c","c|"))
Error in "align<-.xtable"(`*tmp*`, value = switch(1 +
is.null(align), :
"align" must be containing elements of
{"r","l","c"}
So the align attribute won't accept p(1cm) either, for example,
but this might not be the best solution anyway. It seems just as
easy to modify your table after xtable makes it than to modify
xtable to allow such things, since xtable would not save you any
typing time. You could stick in your long headers using
\multicolumn{1}{p(2cm)}{blah blah blah}, or \parbox{}, or just
use two rows. (I haven't tested any of this.)
Jon
--
Jonathan Baron, Professor of Psychology, University of Pennsylvania
Home page: http://www.sas.upenn.edu/~baron
R search page: http://finzi.psych.upenn.edu/
______________________________________________
[EMAIL PROTECTED] mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html