Utility function to translate a factor into colors
Utility function to translate a factor into colors
fac2col( x, s = 1, v = 1, shuffle = FALSE, min.group.size = 1, return.details = FALSE, unclassified.cell.color = "gray50", level.colors = NULL )
x |
input factor |
s |
numeric The "saturation" to be used to complete the HSV color descriptions (default=1) See ?rainbow in Palettes, grDevices |
v |
numeric The "value" to be used to complete the HSV color descriptions (default=1) See ?rainbow in Palettes, grDevices |
shuffle |
boolean If TRUE, shuffles columns with shuffle(columns) (default=FALSE) |
min.group.size |
integer Exclude groups of size less than the min.group.size (default=1) |
return.details |
boolean If TRUE, returns a list list(colors=y, palette=col). Otherwise, just returns the factor (default=FALSE) |
unclassified.cell.color |
Color for unclassified cells (default='gray50') |
level.colors |
(default=NULL) |
vector or list of colors
genes = factor(c("BRAF", "NPC1", "PAX3", "BRCA2", "FMR1")) fac2col(genes)
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.