Span columns within rows
Span columns within rows.
spanFlexTableColumns(object, i, from, to, runs)
- vector (integer index, row.names values or boolean vector) for rows selection.
- index of the first column to span (its content will be the visible one).
- index of the last column to span.
- a vector of size
numcolof FlexTable. If provided, successive runs of equal values will indicate to merge corresponding columns.
Overlappings of horizontally merged cells and vertically merged cells are forbidden.
# mydata = iris[46:55, ] MyFTable = FlexTable( data = mydata ) # merge columns 2 to 4 in line 3 MyFTable = spanFlexTableColumns( MyFTable, i = 2, from = 2, to = 4 ) # merge cells in line 4 when successive values of # a given character vector are identical. Note # the character vector length is the same # than the number of columns of the FlexTable. MyFTable = spanFlexTableColumns( MyFTable, i = 4, runs = c( "a", "b", "b", "c", "d") )
Looks like there are no examples yet.