Description Usage Arguments Value Author(s)
View source: R/get_fill_scale.R
The function can return either a fill scale for a discrete variable or a gradient fill scale for a continuous numeric variable.
1 2 3 4 5 6 |
palette_path |
A string that sets the file path for the .rds file that contains a vector of colors in hexadecimal format. Argument is required. |
scale_title |
A string that sets the title for the scale's legend. By default the title comes from the variable name assigned to the fill aesthetic. |
scale_limits |
A numeric vector of length two that sets the limits of the non-discrete scale based on the variable assigned to the fill aesthetic. |
discrete |
A logical that if TRUE the function returns a discrete fill scale. If FALSE, a gradient fill scale is returned. |
Returns a fill scale object that can be attached to ggplot2 plot object for scaling the fill aesthetic variable.
Rick Dean
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.