Description Usage Arguments Value Examples
Creates a color palette of n distinct colors from a provided image.
1 | create_palette(img, n, prominent.ord = FALSE, hue = NA, ...)
|
img |
Path to image file. |
n |
'n' distinct colors. |
prominent.ord |
Option to choose prominent colors instead of segmenting the colors from a random starting color. |
... |
Additional arguments passed to find_segmented. |
Vector of distinct hex colors.
1 2 3 4 5 | # return 20 semi-evenly distributed colors from some image
create_palette('path/to/image.png', n = 20)
# return the 10 most prominent colors from some image
create_palette('path/to/image.jpg', n = 10, prominent.order = T)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.