<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Recent changes to Colormap</title><link>https://sourceforge.net/p/geoms2/wiki/Colormap/</link><description>Recent changes to Colormap</description><atom:link href="https://sourceforge.net/p/geoms2/wiki/Colormap/feed" rel="self"/><language>en</language><lastBuildDate>Wed, 26 Feb 2014 14:49:25 -0000</lastBuildDate><atom:link href="https://sourceforge.net/p/geoms2/wiki/Colormap/feed" rel="self" type="application/rss+xml"/><item><title>Colormap modified by CMRP Software</title><link>https://sourceforge.net/p/geoms2/wiki/Colormap/</link><description>&lt;div class="markdown_content"&gt;&lt;pre&gt;--- v2
+++ v3
@@ -45,3 +45,30 @@
 plt.show()
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

+
+The result should be similar to this:
+
+[[img src=http://wiki.scipy.org/Cookbook/Matplotlib/Show_colormaps?action=AttachFile&amp;amp;do=get&amp;amp;target=colormaps3.png width=320px align=center]]
+
+
+The names of the colormaps are not always the same for each library. In fact there may be slight changes in the color dispersion for the same colormap in different libraries. [Matplotlib](http://matplotlib.org) has the *seismic* colormap. However [mayavi](http://docs.enthought.com/mayavi/mayavi/) has *RdBu* colormap for a very similar if not identical colormap. To check available [mayavi](http://docs.enthought.com/mayavi/mayavi/) colormaps you can do the following:
+
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+from mayavi.core import lut_manager
+
+print lut_manager.lut_mode_list()
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+
+The result should be this:
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+['Accent', 'Blues', 'BrBG', 'BuGn', 'BuPu', 'Dark2', 'GnBu', 'Greens', 'Greys', 'OrRd', 'Oranges', 'PRGn', 'Paired', 'Pastel1', 'Pastel2', 'PiYG', 'PuBu', 'PuBuGn', 'PuOr', 'PuRd', 'Purples', 'RdBu', 'RdGy', 'RdPu', 'RdYlBu', 'RdYlGn', 'Reds', 'Set1', 'Set2', 'Set3', 'Spectral', 'YlGn', 'YlGnBu', 'YlOrBr', 'YlOrRd', 'autumn', 'binary', 'black-white', 'blue-red', 'bone', 'cool', 'copper', 'file', 'flag', 'gist_earth', 'gist_gray', 'gist_heat', 'gist_ncar', 'gist_rainbow', 'gist_stern', 'gist_yarg', 'gray', 'hot', 'hsv', 'jet', 'pink', 'prism', 'spectral', 'spring', 'summer', 'winter']
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+
+External links
+--------------
+
+- Custom colormap in matplotlib [here](http://matplotlib.org/examples/pylab_examples/custom_cmap.html)
&lt;/pre&gt;
&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">CMRP Software</dc:creator><pubDate>Wed, 26 Feb 2014 14:49:25 -0000</pubDate><guid>https://sourceforge.net2cb79705bcab624d8297cf492f949227860a7399</guid></item><item><title>Colormap modified by CMRP Software</title><link>https://sourceforge.net/p/geoms2/wiki/Colormap/</link><description>&lt;div class="markdown_content"&gt;&lt;pre&gt;--- v1
+++ v2
@@ -23,4 +23,25 @@
 Examples of colormaps
 ---------------------

-The [matplotlib](http://matplotlib.org) library has several available [colormaps](http://matplotlib.org/examples/color/colormaps_reference.html)
+The [matplotlib](http://matplotlib.org) library has several available [colormaps](http://matplotlib.org/examples/color/colormaps_reference.html). The following code recipe adapted from [here](http://wiki.scipy.org/Cookbook/Matplotlib/Show_colormaps) shows you some of the available [matplotlib](http://matplotlib.org) colormaps:
+
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+import numpy as np
+import matplotlib.pyplot as plt
+
+plt.rc('text', usetex=False)
+a=np.outer(np.arange(0,1,0.01),np.ones(10))
+plt.figure(figsize=(10,5))
+plt.subplots_adjust(top=0.8,bottom=0.05,left=0.01,right=0.99)
+maps=[m for m in plt.cm.datad if not m.endswith("_r")]
+maps.sort()
+l=len(maps)+1
+for i, m in enumerate(maps):
+    plt.subplot(1,l,i+1)
+    plt.axis("off")
+    plt.imshow(a,aspect='auto',cmap=plt.get_cmap(m),origin="lower")
+    plt.title(m,rotation=90,fontsize=10)
+plt.show()
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
&lt;/pre&gt;
&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">CMRP Software</dc:creator><pubDate>Wed, 26 Feb 2014 14:38:03 -0000</pubDate><guid>https://sourceforge.netaf42fc8f5087eabaa1d1a47eac2f280e2e72e361</guid></item><item><title>Colormap modified by CMRP Software</title><link>https://sourceforge.net/p/geoms2/wiki/Colormap/</link><description>&lt;div class="markdown_content"&gt;&lt;h1 id="colormap"&gt;Colormap&lt;/h1&gt;
&lt;div class="toc"&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="#colormap"&gt;Colormap&lt;/a&gt;&lt;ul&gt;
&lt;li&gt;&lt;a href="#common-procedure"&gt;Common procedure&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="#examples-of-colormaps"&gt;Examples of colormaps&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/div&gt;
&lt;p&gt;A colormap, or also called a colour look-up table (CLUT), is a mechanism used to transform a range of input colours into another range of colours. It can be a hardware device built into an imaging system or a software function built into an image processing application. The hardware colour look-up table will convert the logical colour (pseudo-colour) numbers stored in each pixel of video memory into physical colours, normally represented as &lt;a class="" href="http://en.wikipedia.org/wiki/RGB_color_model" rel="nofollow"&gt;RGB&lt;/a&gt; triplets, that can be displayed on a computer monitor. The palette is simply a block of fast RAM which is addressed by the logical colour and whose output is split into the red, green, and blue levels which drive the actual display (e.g., a CRT or cathode ray tube).&lt;/p&gt;
&lt;p&gt;&lt;em&gt;in &lt;a class="" href="http://en.wikipedia.org/wiki/Colour_look-up_table" rel="nofollow"&gt;wikipedia - en&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;
&lt;h2 id="common-procedure"&gt;Common procedure&lt;/h2&gt;
&lt;p&gt;Usually to assert some color value to a variable value we retrieve the minimum and maximum of that variable and divide it by the number of colors available in the look up table (like an &lt;a class="" href="http://en.wikipedia.org/wiki/Histogram" rel="nofollow"&gt;histogram&lt;/a&gt;). After that we know what color each value will have since all are separated by bins.&lt;/p&gt;
&lt;p&gt;There are different colormaps depending on the expected purpose. There are colormaps for continuous variables and colormaps for discrete variables. There are colormaps that specifically divide the data into two populations around a center (like seismic or RdBu colormap: red,white,blue or reverse) among other objectives.&lt;/p&gt;
&lt;h2 id="examples-of-colormaps"&gt;Examples of colormaps&lt;/h2&gt;
&lt;p&gt;The &lt;a class="" href="http://matplotlib.org" rel="nofollow"&gt;matplotlib&lt;/a&gt; library has several available &lt;a class="" href="http://matplotlib.org/examples/color/colormaps_reference.html" rel="nofollow"&gt;colormaps&lt;/a&gt;&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">CMRP Software</dc:creator><pubDate>Tue, 25 Feb 2014 13:44:32 -0000</pubDate><guid>https://sourceforge.netdef0652100529170f13c3229a165e9b6ae350fbb</guid></item></channel></rss>