Get and modify colours from objects of class PwfCols

# S4 method for class 'PwfCols'
getColours(object)

# S4 method for class 'PwfCols'
setColours(object, PASS, WARN, FAIL, MAX)

# S4 method for class 'PwfCols'
setAlpha(object, alpha)

Arguments

object

An object of class PwfCols

PASS

The colour denoting PASS on all plots, in rgb format

WARN

The colour denoting WARN on all plots, in rgb format

FAIL

The colour denoting FAIL on all plots, in rgb format

MAX

The colour denoting the limit of values in rgb format

alpha

Numeric(1). Ranges from 0 to 1 by default, but can also be on the range 0 to 255.

Value

getColours will return a character vector of colours coresponding to PASS/WARN/FAIL

setColours will return an object of class PwfCols

setAlpha will return an object of class PwfCols

Details

Use getColours to obtain the colours in an object of class PwfCols.

These can be modified using the functions setColours and setAlpha

Examples

getColours(pwf)
#>      PASS      WARN      FAIL       MAX 
#> "#00CC00" "#E6E633" "#CC3333" "#000000" 

# How to add transparency
pwf2 <- setAlpha(pwf, 0.1)
getColours(pwf2)
#>        PASS        WARN        FAIL         MAX 
#> "#00CC0019" "#E6E63319" "#CC333319" "#00000019"