EVOLUTION-MANAGER
Edit File: choose_palette.html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><title>R: Graphical User Interface for Choosing HCL Color Palettes</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <link rel="stylesheet" type="text/css" href="R.css" /> </head><body> <table width="100%" summary="page for choose_palette {colorspace}"><tr><td>choose_palette {colorspace}</td><td style="text-align: right;">R Documentation</td></tr></table> <h2>Graphical User Interface for Choosing HCL Color Palettes</h2> <h3>Description</h3> <p>A graphical user interface (GUI) for viewing, manipulating, and choosing HCL color palettes. </p> <h3>Usage</h3> <pre> choose_palette(pal = diverging_hcl, n = 7L, parent = NULL, gui = "tcltk", ...) hclwizard(n = 7L, gui = "shiny", ...) </pre> <h3>Arguments</h3> <table summary="R argblock"> <tr valign="top"><td><code>pal</code></td> <td> <p>function; the initial palette, see ‘Value’ below. Only used if <code>gui = "tcltk"</code>.</p> </td></tr> <tr valign="top"><td><code>n</code></td> <td> <p>integer; the initial number of colors in the palette.</p> </td></tr> <tr valign="top"><td><code>parent</code></td> <td> <p>tkwin; the GUI parent window. Only used if <code>gui = "tcltk"</code>.</p> </td></tr> <tr valign="top"><td><code>gui</code></td> <td> <p>character; GUI to use. Available options are <code>tcltk</code> and <code>shiny</code>, see ‘Details’ below.</p> </td></tr> <tr valign="top"><td><code>...</code></td> <td> <p>used for development purposes only.</p> </td></tr> </table> <h3>Details</h3> <p>Computes palettes based on the HCL (hue-chroma-luminance) color model (as implemented by <code><a href="polarLUV.html">polarLUV</a></code>). The GUIs interface the palette functions <code><a href="hcl_palettes.html">qualitative_hcl</a></code> for qualitative palettes, <code><a href="hcl_palettes.html">sequential_hcl</a></code> for sequential palettes with a single or multiple hues, and <code><a href="hcl_palettes.html">diverging_hcl</a></code> for diverging palettes (composed from two single-hue sequential palettes). </p> <p>Two different GUIs are implemented and can be selected using the function input argument <code>gui</code> (<code>"tcltk"</code> or <code>"shiny"</code>). Both GUIs allows for interactive modification of the arguments of the respective palette-generating functions, i.e., starting/ending hue (wavelength, type of color), minimal/maximal chroma (colorfulness), minimal maximal luminance (brightness, amount of gray), and a power transformations that control how quickly/slowly chroma and/or luminance are changed through the palette. Subsets of the parameters may not be applicable depending on the type of palette chosen. See <code><a href="hcl_palettes.html">qualitative_hcl</a></code> and Zeileis et al. (2009, 2019) for a more detailed explanation of the different arguments. Stauffer et al. (2015) provide more examples and guidance. </p> <p>Optionally, active palette can be illustrated by using a range of examples such as a map, heatmap, scatter plot, perspective 3D surface etc. </p> <p>To demonstrate different types of deficiencies, the active palette may be desaturated (emulating printing on a grayscale printer) and collapsed to emulate different types of color-blindness (without red-green or green-blue contrasts) using the <code><a href="simulate_cvd.html">simulate_cvd</a></code> functions. </p> <p><code>choose_palette</code> by default starts the Tcl/Tk version of the GUI while <code>hclwizard</code> by default starts the shiny version. <code>hcl_wizard</code> is an alias for <code>hclwizard</code>. </p> <h3>Value</h3> <p>Returns a palette-generating function with the selected arguments. Thus, the returned function takes an integer argument and returns the corresponding number of HCL colors by traversing HCL space through interpolation of the specified hue/chroma/luminance/power values. </p> <h3>Author(s)</h3> <p>Jason C. Fisher, Reto Stauffer, Achim Zeileis </p> <h3>References</h3> <p>Zeileis A, Hornik K, Murrell P (2009). Escaping RGBland: Selecting Colors for Statistical Graphics. <em>Computational Statistics & Data Analysis</em>, <b>53</b>, 3259–3270. doi: <a href="http://doi.org/10.1016/j.csda.2008.11.033">10.1016/j.csda.2008.11.033</a> Preprint available from <a href="https://eeecon.uibk.ac.at/~zeileis/papers/Zeileis+Hornik+Murrell-2009.pdf">https://eeecon.uibk.ac.at/~zeileis/papers/Zeileis+Hornik+Murrell-2009.pdf</a>. </p> <p>Stauffer R, Mayr GJ, Dabernig M, Zeileis A (2015). Somewhere over the Rainbow: How to Make Effective Use of Colors in Meteorological Visualizations. <em>Bulletin of the American Meteorological Society</em>, <b>96</b>(2), 203–216. doi: <a href="http://doi.org/10.1175/BAMS-D-13-00155.1">10.1175/BAMS-D-13-00155.1</a> </p> <p>Zeileis A, Fisher JC, Hornik K, Ihaka R, McWhite CD, Murrell P, Stauffer R, Wilke CO (2019). “ccolorspace: A Toolbox for Manipulating and Assessing Colors and Palettes.” arXiv:1903.06490, arXiv.org E-Print Archive. <a href="http://arxiv.org/abs/1903.06490">http://arxiv.org/abs/1903.06490</a> </p> <h3>See Also</h3> <p><code><a href="simulate_cvd.html">simulate_cvd</a></code>, <code><a href="desaturate.html">desaturate</a></code>, <code><a href="hcl_palettes.html">qualitative_hcl</a></code>. </p> <h3>Examples</h3> <pre> if(interactive()) { ## Using tcltk GUI pal <- choose_palette() ## or equivalently: hclwizard(gui = "tcltk") ## Using shiny GUI pal <- hclwizard() ## or equivalently: choose_palette(gui = "shiny") ## use resulting palette function filled.contour(volcano, color.palette = pal, asp = 1) } </pre> <hr /><div style="text-align: center;">[Package <em>colorspace</em> version 1.4-1 <a href="00Index.html">Index</a>]</div> </body></html>