Description Usage Arguments Value Examples
Invert a vector of colors, provided the colors are valid hex codes or have valid names (i.e., they belong to base::colors()), and return a vector of inverted colors in hex code.
1 2 3 | invert_color(color, colour = color)
invert_colour(color, colour = color)
|
color |
color(s) to invert |
colour |
alias of color |
Inverted color(s) in hex code
1 2 3 4 | invert_color("white") # "black"
invert_color("gray20") # "gray80"
invert_color("grey80") # "grey20"
invert_color(c("#000000", "#333333")) # "#FFFFFF","#CCCCCC"
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.