scale_colour_ifs: Title Add IFS colours to a ggplot A wrapper for...

Description Usage Arguments Functions Examples

View source: R/ggIFS.R

Description

Title Add IFS colours to a ggplot A wrapper for scale_colour_manual / scale_fill_manual that allows the user to specify a certain colour palette, or ask for specific IFS colours.

Usage

1
2
3
scale_colour_ifs(palette = "default", values = NA, gradient = FALSE, ...)

scale_fill_ifs(palette = "default", values = NA, gradient = FALSE, ...)

Arguments

palette

The default option are the IFS mid-colours. Accepted values are "greens", "greys", "blues", "reds", "yellows", "purples".

values

For manually entering colour values. The allowed values are "dark_X_2", "dark_X_1", "mid_X", "light_X_1", "light_X_2", "light_X_3". Replace X with green, grey, blue, red, yellow, purple.

gradient

If true, acts as a wrapper for scale_colour_gradientn or scale_fill_gradientn.

...

Other values to pass to scale_colour_manual or scale_fill_manual

Functions

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
ggplot(iris, aes(x = Sepal.Width, y = Sepal.Length, colour = Species)) +
geom_point() +
scale_colour_ifs()

ggplot(iris, aes(x = Sepal.Width, y= Sepal.Length, colour = Species)) +
geom_point() +
scale_colour_ifs(values = c("dark_green_2", "mid_red", "light_yellow_3"))

ggplot(iris, aes(x = Sepal.Width, y = Sepal.Length, colour = Petal.Length)) +
geom_point() +
scale_colour_ifs(palette = "greys", gradient = TRUE)

vedanthnair/ggIFS documentation built on Jan. 14, 2022, 7:39 p.m.