ReporteRs (version 0.4)

addFlexCellContent: Add content in a FlexTable

Description

add texts or paragraphs in cells contents of a FlexTable object

Usage

addFlexCellContent(object, i, j, value, textProperties,
    newpar = F, byrow = FALSE)

Arguments

object

a FlexTable object

i

vector (integer index, row.names values or boolean vector) for rows.

j

vector (integer index, col.names values or boolean vector) for columns.

value

text values or values that have a format method returning character value.

textProperties

formating properties (an object of class textProperties).

newpar

logical value specifying wether or not the content should be added as a new paragraph

byrow

logical. If FALSE (the default) content is added by columns , otherwise content is added by rows.

See Also

addFlexTable

Examples

Run this code
# NOT RUN {
data( data_ReporteRs )
myFlexTable = FlexTable( data = data_ReporteRs
	, span.columns = "col1"
	, header.columns = TRUE
	, row.names = FALSE )
myFlexTable = addFlexCellContent( myFlexTable
	, i = 1:4, j = 1
	, value = c("A", "B", "C", "D")
	, textProperties = textProperties( color="red" )
	)
myFlexTable = addFlexCellContent( myFlexTable
	, i = 1:4, j = 2
	, value = c("E", "F", "G", "H")
	, textProperties = textProperties( color="red" )
	, newpar = TRUE
	)
# }

Run the code above in your browser using DataCamp Workspace