set_alpha | R Documentation |
Set alpha value of integer colors
set_alpha(icol, alpha)
icol |
Integer vector (where the 4 bytes making up each integer represent the RGBA values of the color) |
alpha |
numeric alpha value in range [0, 1]. Length of 1, or same length as 'col' |
integer vector of colors with adjusted alpha channel
icol <- col_to_int('red')
icol
int_to_col(icol)
icol2 <- set_alpha(icol, 0.5)
int_to_col(icol2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.