print_color_list | R Documentation |
Print color list of color vectors or color functions
print_color_list(
x,
do_print = TRUE,
colorized = TRUE,
digits = 4,
max_entries = Inf,
...
)
x |
|
do_print |
|
colorized |
|
digits |
|
max_entries |
|
... |
additional arguments are ignored. |
list
named by names(x)
of the input data,
each element contains a character
vector of R colors
named by respective label. The names are derived either directly
from the input color vector, or by the attr(i, "breaks")
encoded into the color function by circlize::colorRamp2()
.
Other jam color functions:
assign_numeric_colors()
,
design2colors()
,
df_to_numcolors()
,
mean_hue()
,
quick_complement_color()
# generate example data.frame of annotations
n <- 100;
set.seed(12);
anno_df <- data.frame(
group=sample(c("A", "B", "B"),
size=n,
replace=TRUE),
tss_score=rnorm(n) + 4,
h3k4me1_score=rnorm(n) + 4
);
# generate a list of colors for the data.frame
scl <- design2colors(anno_df,
group_colnames="group",
color_sub=c(tss_score="royalblue",
h3k4me1_score="slateblue"),
plot_type="none")
# print the list of colors, color functions, in colorized text
print_color_list(scl)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.