[R] How to combine xtable and minipage with Sweave ?
Duncan Murdoch
murdoch at stats.uwo.ca
Mon Mar 16 11:40:11 CET 2009
Ptit_Bleu wrote:
> Dear Duncan,
>
> Thanks for the tips, but I haven't found a way to modify your solution so
> that I can include a table and not a graph (includegraphics works for
> graphs, I need an 'includetable', I think).
>
Sorry, I misread your request. (I saw the letters t, a, b, l, e and
read "figure".) You need xtable to make a compatible header for your
table. I haven't read the whole thread, but I think the problem is in
using \begin{table}, rather than just going straight into a tabular
environment. I believe you can avoid this by using the argument
"floating=FALSE" when you print the xtable. So the code in your Sweave
file would look something like
print(xtable(rg), include.rownames=F, size="\\tiny", floating=FALSE)
See ?print.xtable for more options if this doesn't work.
Duncan Murdoch
> I found scripts like yours explaining how to include graphs into table but
> this is not my case:
> My problem doesn't come from the graph but from the table ('maybe' my
> english is not so clear).
>
> Do I need to convert the table into a graph (and how) ?
>
> Sorry again for such basic questions.
> Thank you for your help.
> Ptit Bleu.
>
>
More information about the R-help
mailing list