how to express statistical data in colors

Chloe Lewis

PhD candidate, Harte Lab
Division of Ecosystem Sciences, ESPM
University of California, Berkeley
137 Mulford Hall
Berkeley, CA 94720
chlewis@…1016…

···

Begin forwarded message:

From: Chloe Lewis <chlewis@…1016…>

Subject: Re: [Matplotlib-users] how to express statistical data in colors

Date: October 26, 2012 10:47:54 AM PDT

To: rand0m@…4228…

you’ll be doing something like the second color bar, but making the boundary and color definitions a lot more flexible. Where the discrete color bar uses

cmap = mpl.colors.ListedColormap(['r', 'g', 'b', 'c'])
bounds = [1, 2, 4, 7, 8]
you'll be making a whole LinearSegmentedColormap, see
[http://matplotlib.org/api/colors_api.html#matplotlib.colors.LinearSegmentedColormap](http://matplotlib.org/api/colors_api.html#matplotlib.colors.LinearSegmentedColormap)
and check out specifically the ascii-art explanation of interpolation between row[i] and row[i+1]. Red, green, blue will break based on your data density and how you want to express 'intensity'. And depending on whether you'll make it red-green-colorblindness neutral!
Interesting problem. Has it been implemented in some other software?


Chloe Lewis

PhD candidate, Harte Lab
Division of Ecosystem Sciences, ESPM
University of California, Berkeley
137 Mulford Hall
Berkeley, CA 94720
chlewis@…1016…