Learn R Programming

inTextSummaryTable (version 3.3.2)

getColorPaletteTable: Get color palette for the tables

Description

This function gets the color palettes for the tables specified as global options.

Usage

getColorPaletteTable(style = c("report", "presentation"))

Value

A named vector with hex colors.

Arguments

style

String with style of report. Either 'report' or 'presentation'. By default, the style is 'report'.

Details

By default, the function returns the palette of the package. The user can specify a custom palette by setting the global options.

Examples

Run this code
# report style (the default)
getColorPaletteTable()
# presentation style
getColorPaletteTable(style = "presentation")
# custom palette
customColorTable <- c('header' = "#FFFFFF",'headerBackground' = "#3F4788FF", 
'body' = "#000000", 'bodyBackground1' = "#D9D9D9", 'bodyBackground2' = "#D9D9D9", 
'footer' = "#000000", 'footerBackground' = "#FFFFFF",'line' = "#FFFFFF")
options(inTextSummaryTable.colors.table.presentation = customColorTable)
getColorPaletteTable("presentation")

Run the code above in your browser using DataLab