if (FALSE) # Windows-specific example
wrd <- GetNewWrd()
wtab <- WrdTable(nrow=3, ncol=5, wrd=wrd)
# insert headings and merge 1:2 and 4:5, such as there are
# only 3 headings
WrdTableHeading(wtab, text=c("First","Second",
"Third"),
alignment=c(wdConst$wdAlignParagraphLeft,
rep(wdConst$wdAlignParagraphCenter, 2)),
merge_cols = c("1:2", "4:5"))
Run the code above in your browser using DataLab