Re: [R] Log color scale

From: Thomas Lumley <tlumley_at_u.washington.edu>
Date: Tue 01 Aug 2006 - 00:25:54 EST

On Sun, 30 Jul 2006, Uwe Ligges wrote:

> vincent@7d4.com wrote:
>
>> Kartik Pappu a écrit :
>>
>>
>>> However I need to plot my data in a log transformed color scale. Is
>>> this possible? I will be happy to explain further, but basically I
>>> need to do this because there are large variations in the max and min
>>> values of my raw data and I am trying to highlight the differences in
>>> the values at the lower end of my raw data (while still displaying the
>>> values at the high end of the spectrum for comparison) so if figured
>>> the best way to represent this on a (RGB) color scale is to do it with
>>> a log transform. I do not want to use too many colors because that
>>> make the figure too busy.
>>> Any suggestions on how to achieve this.

>>
>>
>> Don't use too much time to search a good palette, build it yourself.
>
> It is worth looking into the packages "RColorBrewer" and "colorspace".
> Some people thought about colors in graphics and wrote some code that
> might result in more appropriate colors and palettes than those that are
> quickly hacked...
>

colorRampPalette() will interpolate between colors (eg those from one of the ColorBrewer palettes) and has a bias= argument to make the colors closer together at one end of the scale.

         -thomas

Thomas Lumley			Assoc. Professor, Biostatistics
tlumley@u.washington.edu	University of Washington, Seattle

______________________________________________

R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Tue Aug 01 01:48:30 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Tue 01 Aug 2006 - 02:17:08 EST.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.