View source: R/merge_colnames.R
merge_colnames | R Documentation |
xtable
's add.to.row
when column names are repeated and
should be merged.Removes consecutive duplicate column names and uses LaTeX's \multicolumn
to
merge the cells. Shuld be passed to add.to.row
in print.xtable()
.
merge_colnames(xtab)
xtab |
an object of class |
a list with components 'pos' and 'command'
iris2 <- split_colnames(iris, sep = "\\.")
xtab <- xtable::xtable(iris2)
xtable::print.xtable(xtab, add.to.row = merge_colnames(xtab))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.