

You can find more examples of xtable in action in the package vignette. I also tweaked the border=”1″ table directive to border=”0″ - if you have a decent Web editor you could pretty the table up further to your heart’s desire. For example, to create the table above, I simply did the following: > fm2 print(xtable(anova(fm2)), type="html")Īnd then pasted the HTML it generated straight into this blog post.

It’s a handy tool for converting the output of many of R’s statistical functions into a presentation-ready table in LaTeX or HTML format. That’s great when you’re doing exploratory analysis, but what about when you want to include R output in a report or publication? In other words, what if you want to convert this Analysis of Variance table:Įthnicty 3 2572.1 857.38 4.3147 0.006781 **

Important note for package binaries: R-Forge provides these binaries only for the most recent version of R, but not for older versions. Below is a list of all packages provided by project xtable. When you use R at the command-line, the textual output is limited by the medium: one monospaced font, with no typesetting of any kind. R Development Page Contributed R Packages.
