There are now quite a few R packages to turn cross-tables and fitted models into nicely formatted latex. In a previous post I showed how to use one of them to display regression tables on the fly. In this post I summarise what types of R object each of the major packages can deal with.
Unsurprisingly, there’s quite some variation…
I should note that all of these packages also allow users to add their own latex representation for new R objects.
For example, here’s an addition to memisc to cover mer objects from the lme4 package (now included in memisc). However, I couldn’t be bothered to track down all these additions, so this post only deals with what each package can do without any extra work.
Also, several of these packages can typeset data.frame and matrix objects too. While that can be incredibly handy, it is outside the focus of this post so I’ve left it out. Cross-tables are only just processed enough to deserve a mention. And we won’t even talk about generating HTML (well, not until the notes anyway).
Finally, I haven’t checked all of this information. The table is filled on the basis of my experience and the package documentation. If something is wrong or incomplete then please let me know in the comments.
|gee||gee||Y||Y||Y (in ‘skeleton’ form)|
|survey||svyglm||Y||Y||Y (in ‘skeleton’ form)|
In case you are curious, a first version of this table was generated using the print.xtable function of the xtable package with type=html before being adjusted in place. If these posts haven’t given you the idea yet: I detest doing this sort of thing by hand.