| tate_sample | R Documentation |
This function allows you to generate a colour palette from an image.
tate_sample(path, n = 4, type = "discrete", direction = 1, plot = TRUE)
path |
The file path or url of the image you wish to sample colours from. |
n |
The number of colours to sample from the image. If n is not provided, the length of the palette defaults to 4. |
type |
Specify either "discrete" or "continuous". If "continuous", three colours are sampled from the image and automatically interpolated between. Defaults to "discrete". |
direction |
Specify the order of colours. Defaults to 1. If direction is -1, palette is reversed. |
plot |
(Logical) Plot sampled colour palette. Defaults to TRUE. |
url <- "https://t4.ftcdn.net/jpg/02/90/91/11/240_F_290911157_rJMt9bp5sq64hyY6TklM9XS5GoDg07Vh.jpg" london_sample(path = url, n = 4, type = "discrete")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.