View source: R/prepare_scales.R
remove_duplicate_scales | R Documentation |
If a mixed layout uses the same aesthetic for both triangles and only one (or no) colour or size scale has been specified, remove redundant scales.
remove_duplicate_scales(
scale_vec,
col_scale = NULL,
size_scale = NULL,
bins,
limits,
high,
mid,
low,
na_col,
midpoint,
size_range
)
scale_vec |
Vector of scale aesthetics. |
col_scale |
Input colour scales (NULL, string or scale object). |
size_scale |
Input size scales. |
bins |
Numeric for number of bins to determine if multiple scales are needed (if multiple bins values). |
limits |
Limits of scale (list of limits if two scales). |
high |
Colours at high values (correlation heatmap). |
mid |
Colours at medium values (correlation heatmap). |
low |
Colours at low values (correlation heatmap). |
na_col |
Colour if NA. |
midpoint |
Midpoint of divergent scale (correlation heatmap). |
size_range |
Size range (list of ranges if two scales). |
Vector of aesthetics with duplicates removed if appropriate.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.