Learn R Programming

wrMisc (version 1.14.1)

.chooseGrpCol: Automatic choice of colors

Description

This function allows to do automatic choice of colors: if single-> grey, if few -> RColorBrewer, if many : gradient green -> grey/red

Usage

.chooseGrpCol(nGrp, paired = FALSE, alph = 0.2)

Value

character vector with color codes

Arguments

nGrp

(numeric vector) main input

paired

(logical)

alph

(numeric vector)

See Also

rgb; colorAccording2

Examples

Run this code
.chooseGrpCol(4)	

Run the code above in your browser using DataLab