I need to create a table with some merged cells, you can consider it as a normal dataframe with 10 columns, 1:3 columns will be described on top using a merged cell, and another for 4:10 columns.
Is there any package in R for me to do? like xtable?
I need to create a table with some merged cells, you can consider it as a normal dataframe with 10 columns, 1:3 columns will be described on top using a merged cell, and another for 4:10 columns.
Is there any package in R for me to do? like xtable?
You can do it in Open Document Format (readable, editable in OpenOffice or Ms Office) with odfWeave package.
Example from documentation (see formatting.odt in package source/inst/examples):
library(odfWeave)
set.seed(416)
tableData <- state.x77[c(7, 38, 20, 46), c(7, 1, 8)]
states <- data.frame(type = c("Northern", "Southern"),
pos = c(2, 2),
text = "ArialCenteredItalics")
odfTable(tableData, rgroup = states)
odfTableCaption("a table using multi-cell row headers")