scale_color_discrete: Apply the Brattle palette to ggplot figures

Description Usage Arguments Details Author(s) See Also Examples

View source: R/scale_color_discrete.R

Description

These functions override the standard ggplot versions to apply the Brattle palette to ggplot figures.

Usage

1
2
3

Arguments

...

Arguments passed to corresponding ggplot function (see below)

Details

Note that the Brattle palette is only applied if there are five or fewer groups. If there are more than five groups, colors from the viridis package are applied.

Author(s)

Charlie Gibbons

See Also

scale_colour_discrete, scale_fill_discrete from the ggplot2 package

Examples

1
2
3
4
qplot(carat, price, data = diamonds, color = cut) + scale_color_discrete("Cut")

### Revert to the ggplot version
qplot(carat, price, data = diamonds, color = cut) + ggplot2::scale_color_discrete("Cut")

Brattle/BrattleExtras documentation built on Oct. 17, 2018, 8:58 a.m.