# NOT RUN {
library(ggplot2)
library(colorspace) # for desaturate
p <- ggplot(iris, aes(Sepal.Width, fill=Species)) +
geom_density(alpha = 0.7)
p2 <- edit_colors(p, deutan)
p3 <- edit_colors(p, tritan, sev = 7)
p4 <- edit_colors(p, desaturate)
cowplot::plot_grid(p, p2, p3, p4)
# }
Run the code above in your browser using DataLab