Adds a row of cells <td>val</td><td>...</td> to a table string for
htmlTable
prAddCells(rowcells, cellcode, align, style, cgroup_spacer_cells,
has_rn_col, col.columns, offset = 1, css.cell)
The cells with the values that are to be added
Type of cell, can either be th
or td
A character strings specifying column alignments, defaulting to
paste(rep('c',ncol(x)),collapse='')
to center. Valid alignments are
l = left, c = center and r = right. You can also specify align='c|c'
and
other LaTeX tabular formatting. If you want to set the alignment of the
rownames this string needst to be ncol(x) + 1
, otherwise it automatically
pads the string with a left alignment for the rownames.
The cell style
The number of cells that occur between columns due to the cgroup arguments.
Due to the alignment issue we need to keep track of if there has already been printed a rowname column or not and therefore we have this has_rn_col that is either 0 or 1.
Alternating colors for each column.
For rgroup rows there may be an offset != 1
The css.cell but only for this row compared to the htmlTable matrix
string
Returns the string with the new cell elements
Other hidden helper functions for htmlTable
: prAddSemicolon2StrEnd
,
prEscapeHtml
,
prGetCgroupHeader
,
prGetRowlabelPos
, prGetStyle
,
prPrepareAlign
,
prPrepareCgroup
, prTblNo