[R] Is there a way to convert rgb/hex value to a (nearest) color name?

Duncan Murdoch murdoch at stats.uwo.ca
Mon Nov 30 20:39:44 CET 2009


On 30/11/2009 2:25 PM, Jorgy Porgee wrote:
> Hi all, I'm trying to convert a series of rgb codes into a color name.
> What is my easiest option? So far I'm stuck with just converting to
> hex using rgb() and I know R knows a number of colours() but a mapping
> of the two has failed me.
>
> Any help in this regard will be highly appreciated.
>
>   

Here's a recent post on this by Barry Rowlingson:

http://finzi.psych.upenn.edu/Rhelp08/2009-October/214886.html

Duncan Murdoch




More information about the R-help mailing list