cvdPlot {colorBlindness} | R Documentation |
Show color-deficiency simulations of a plot
Description
Plot the color-deficiency simulations for ggplot grob.
Usage
cvdPlot(
plot = last_plot(),
layout = c("origin", "deuteranope", "protanope", "desaturate")
)
Arguments
plot |
The grob to be plotted. |
layout |
The sub-figure types. the choices are origin, deuteranope, protanope, desaturate, and enhanced, enhanced.deuteranope, enhanced.protanope, enhanced.desaturate. |
Details
This function is modified from <https://github.com/clauswilke/colorblindr>
Value
An object of ggplot.
Examples
cvdPlot(displayColors(safeColors))
cvdPlot(displayColors(paletteMartin))
[Package colorBlindness version 0.1.9 Index]