getDistinctColors: Get distinct colors

Description Usage Arguments Details Value Author(s) Examples

Description

Get a set of distinct colors selected from colors.

Usage

1
2
getDistinctColors(n, start.color = "blue4", exclude.colors = c("white",
  "black", "gray", "grey"), exclude.rgb.above = 210)

Arguments

n

Number of colors to select.

start.color

Color to start the selection process from.

exclude.colors

Character vector with colors that should not be used.

exclude.rgb.above

Exclude colors where all RGB values are above. This is useful to exclude whitish colors.

Details

The function computes the euclidian distance between all colors and iteratively selects those that have the furthest closes distance to the set of already selected colors.

Value

A character vector with colors.

Author(s)

Aaron Taudt

Examples

1
2
cols <- getDistinctColors(5)
pie(rep(1,5), labels=cols, col=cols)


Search within the chromstaR package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.