| scale_colour_ios_light | R Documentation |
These scales meant to be used with light themes, e.g, theme_sf_light().
While they can be used with dark themes, in general, we recommend pairing
scale_colour_*_lights with light themes for better clarity and contrast.
Notes
While iOS color palettes provide a total of 9 colors, we do not recommend using them for more than 6 groups. The last three colors often collide with other colors in the palette and may affect the clarity of your visualization.
See iOS colors for more details on raw colors.
scale_colour_ios_light(order = "contrast", accessible = FALSE, ...) scale_fill_ios_light(order = "contrast", accessible = FALSE, ...)
order |
Indicates the order of colors in the palette |
accessible |
Indicates whether the accessible set of colors should be used |
... |
Arguments passed on to
|
Other colour scales:
scale_colour_ios_dark(),
scale_colour_ios_gray_dark(),
scale_colour_ios_gray_light(),
scale_colour_macos_dark(),
scale_colour_macos_light(),
scale_colour_watchos_dark()
## Not run:
library(ggplot2)
ggplot(mtcars, aes(y = mpg, x = as.factor(cyl))) +
geom_boxplot(aes(color = as.factor(cyl), fill = as.factor(cyl))) +
labs(x = "Miles Per Gallon", y = "MPG",
fill = "Number of Cylinders",
color = "Number of Cylinders",
title = "Fuel Economy",
subtitle = "Fuel economy declines as engines gets bigger",
caption = "Data from the 1974 Motor Trend US magazine.") +
theme_sf_light() +
scale_fill_ios_light() +
scale_colour_ios_light()
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.