These scale functions help alter ggplot2 colour and fill to colours in the UiO branding scheme. See the colour palettes in uio_pal for variations you can choode from.

scale_colour_uio(palette = "redblack", discrete = TRUE, reverse = FALSE, ...)

scale_color_uio(palette = "redblack", discrete = TRUE, reverse = FALSE, ...)

scale_fill_uio(palette = "redblack", discrete = TRUE, reverse = FALSE, ...)

Arguments

palette

Character name of palette in uio_pal.

discrete

Logical indicating whether colour aesthetic is discrete or not

reverse

Logical indicating whether the palette should be reversed

...

Additional arguments passed to discrete_scale or scale_color_gradientn, used respectively when discrete is TRUE or FALSE

Examples

library(ggplot2) ggplot(mtcars, aes(mpg, disp, colour = cyl)) + geom_point(size = 5) + scale_colour_uio(discrete = FALSE)
ggplot(mtcars, aes(mpg, disp, colour = cyl)) + geom_point(size = 5) + scale_colour_uio(discrete = FALSE, reverse = TRUE)
ggplot(mtcars, aes(mpg, disp, colour = cyl)) + geom_point(size = 5) + scale_colour_uio(discrete = FALSE)
ggplot(mtcars, aes(mpg, disp, colour = factor(cyl))) + geom_point(size = 5) + scale_colour_uio()