Menu

[r1078]: / trunk / htdocs / matplotlib.cm.html.template  Maximize  Restore  History

Download this file

105 lines (89 with data), 15.8 kB

@header@
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="heading">
<tr bgcolor="#7799ee">
<td valign=bottom>&nbsp;<br>
<font color="#ffffff" face="helvetica, arial">&nbsp;<br><big><big><strong><a href="matplotlib.html"><font color="#ffffff">matplotlib</font></a>.cm</strong></big></big></font></td
><td align=right valign=bottom
><font color="#ffffff" face="helvetica, arial"><a href=".">index</a><br><a href="file:/usr/local/lib/python2.3/site-packages/matplotlib/cm.py">/usr/local/lib/python2.3/site-packages/matplotlib/cm.py</a></font></td></tr></table>
    <p><tt>This&nbsp;module&nbsp;contains&nbsp;the&nbsp;instantiations&nbsp;of&nbsp;color&nbsp;mapping&nbsp;classes</tt></p>
<p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#aa55cc">
<td colspan=3 valign=bottom>&nbsp;<br>
<font color="#fffff" face="helvetica, arial"><big><strong>Modules</strong></big></font></td></tr>
    
<tr><td bgcolor="#aa55cc"><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="matplotlib.colors.html">matplotlib.colors</a><br>
</td><td width="25%" valign=top><a href="sys.html">sys</a><br>
</td><td width="25%" valign=top></td><td width="25%" valign=top></td></tr></table></td></tr></table><p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#ee77aa">
<td colspan=3 valign=bottom>&nbsp;<br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Classes</strong></big></font></td></tr>
    
<tr><td bgcolor="#ee77aa"><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
<td width="100%"><dl>
<dt><font face="helvetica, arial"><a href="matplotlib.cm.html#ScalarMappable">ScalarMappable</a>
</font></dt></dl>
 <p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#ffc8d8">
<td colspan=3 valign=bottom>&nbsp;<br>
<font color="#000000" face="helvetica, arial"><a name="ScalarMappable">class <strong>ScalarMappable</strong></a></font></td></tr>
    
<tr bgcolor="#ffc8d8"><td rowspan=2><tt>&nbsp;&nbsp;&nbsp;</tt></td>
<td colspan=2><tt>This&nbsp;is&nbsp;a&nbsp;mixin&nbsp;class&nbsp;to&nbsp;support&nbsp;scalar&nbsp;-&gt;&nbsp;RGBA&nbsp;mapping.&nbsp;&nbsp;Handles<br>
normalization&nbsp;and&nbsp;colormapping<br>&nbsp;</tt></td></tr>
<tr><td>&nbsp;</td>
<td width="100%">Methods defined here:<br>
<dl><dt><a name="ScalarMappable-__init__"><strong>__init__</strong></a>(self, norm<font color="#909090">=None</font>, cmap<font color="#909090">=None</font>)</dt><dd><tt>norm&nbsp;is&nbsp;a&nbsp;colors.Norm&nbsp;instance&nbsp;to&nbsp;map&nbsp;luminance&nbsp;to&nbsp;0-1<br>
cmap&nbsp;is&nbsp;a&nbsp;cm&nbsp;colormap&nbsp;instance</tt></dd></dl>

<dl><dt><a name="ScalarMappable-add_observer"><strong>add_observer</strong></a>(self, mappable)</dt><dd><tt>whenever&nbsp;the&nbsp;norm,&nbsp;clim&nbsp;or&nbsp;cmap&nbsp;is&nbsp;set,&nbsp;call&nbsp;the&nbsp;notify<br>
instance&nbsp;of&nbsp;the&nbsp;mappable&nbsp;observer&nbsp;with&nbsp;self.<br>
&nbsp;<br>
This&nbsp;is&nbsp;designed&nbsp;to&nbsp;allow&nbsp;one&nbsp;image&nbsp;to&nbsp;follow&nbsp;changes&nbsp;in&nbsp;the<br>
cmap&nbsp;of&nbsp;another&nbsp;image</tt></dd></dl>

<dl><dt><a name="ScalarMappable-autoscale"><strong>autoscale</strong></a>(self)</dt><dd><tt>Autoscale&nbsp;the&nbsp;scalar&nbsp;limits&nbsp;on&nbsp;the&nbsp;norm&nbsp;instance&nbsp;using&nbsp;the<br>
current&nbsp;array</tt></dd></dl>

<dl><dt><a name="ScalarMappable-changed"><strong>changed</strong></a>(self)</dt><dd><tt>Call&nbsp;this&nbsp;whenever&nbsp;the&nbsp;mappable&nbsp;is&nbsp;changed&nbsp;so&nbsp;observers&nbsp;can<br>
update&nbsp;state</tt></dd></dl>

<dl><dt><a name="ScalarMappable-notify"><strong>notify</strong></a>(self, mappable)</dt><dd><tt>If&nbsp;this&nbsp;is&nbsp;called&nbsp;then&nbsp;we&nbsp;are&nbsp;pegged&nbsp;to&nbsp;another&nbsp;mappable.<br>
Update&nbsp;the&nbsp;cmap,&nbsp;norm&nbsp;accordingly</tt></dd></dl>

<dl><dt><a name="ScalarMappable-set_array"><strong>set_array</strong></a>(self, A)</dt><dd><tt>Set&nbsp;the&nbsp;image&nbsp;array&nbsp;from&nbsp;numeric/numarray&nbsp;A</tt></dd></dl>

<dl><dt><a name="ScalarMappable-set_clim"><strong>set_clim</strong></a>(self, vmin<font color="#909090">=None</font>, vmax<font color="#909090">=None</font>)</dt><dd><tt>set&nbsp;the&nbsp;norm&nbsp;limits&nbsp;for&nbsp;image&nbsp;scaling</tt></dd></dl>

<dl><dt><a name="ScalarMappable-set_cmap"><strong>set_cmap</strong></a>(self, cmap)</dt><dd><tt>set&nbsp;the&nbsp;colormap&nbsp;for&nbsp;luminance&nbsp;data</tt></dd></dl>

<dl><dt><a name="ScalarMappable-set_colorbar"><strong>set_colorbar</strong></a>(self, im, ax)</dt><dd><tt>set&nbsp;the&nbsp;colorbar&nbsp;image&nbsp;and&nbsp;axes&nbsp;associated&nbsp;with&nbsp;mappable</tt></dd></dl>

<dl><dt><a name="ScalarMappable-set_norm"><strong>set_norm</strong></a>(self, norm)</dt><dd><tt>set&nbsp;the&nbsp;normalization&nbsp;instance</tt></dd></dl>

<dl><dt><a name="ScalarMappable-to_rgba"><strong>to_rgba</strong></a>(self, x, alpha<font color="#909090">=1.0</font>)</dt></dl>

</td></tr></table></td></tr></table><p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#eeaa77">
<td colspan=3 valign=bottom>&nbsp;<br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Functions</strong></big></font></td></tr>
    
<tr><td bgcolor="#eeaa77"><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
<td width="100%"><dl><dt><a name="-ColormapJet"><strong>ColormapJet</strong></a>(N<font color="#909090">=256</font>)</dt></dl>
 <dl><dt><a name="-Grayscale"><strong>Grayscale</strong></a>(N<font color="#909090">=256</font>)</dt></dl>
 <dl><dt><a name="-get_cmap"><strong>get_cmap</strong></a>(name<font color="#909090">=None</font>, lut<font color="#909090">=None</font>)</dt><dd><tt>Get&nbsp;a&nbsp;colormap&nbsp;instance,&nbsp;defaulting&nbsp;to&nbsp;rc&nbsp;values&nbsp;if&nbsp;name&nbsp;is&nbsp;None</tt></dd></dl>
</td></tr></table><p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#55aa55">
<td colspan=3 valign=bottom>&nbsp;<br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
    
<tr><td bgcolor="#55aa55"><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
<td width="100%"><strong>LUTSIZE</strong> = 256<br>
<strong>autumn</strong> = &lt;matplotlib.colors.LinearSegmentedColormap instance&gt;<br>
<strong>bone</strong> = &lt;matplotlib.colors.LinearSegmentedColormap instance&gt;<br>
<strong>cool</strong> = &lt;matplotlib.colors.LinearSegmentedColormap instance&gt;<br>
<strong>copper</strong> = &lt;matplotlib.colors.LinearSegmentedColormap instance&gt;<br>
<strong>datad</strong> = {'autumn': {'blue': ((0.0, 0.0, 0.0), (1.0, 0.0, 0.0)), 'green': ((0.0, 0.0, 0.0), (1.0, 1.0, 1.0)), 'red': ((0.0, 1.0, 1.0), (1.0, 1.0, 1.0))}, 'bone': {'blue': ((0.0, 0.0, 0.0), (0.36507899999999999, 0.44444400000000001, 0.44444400000000001), (1.0, 1.0, 1.0)), 'green': ((0.0, 0.0, 0.0), (0.36507899999999999, 0.31944400000000001, 0.31944400000000001), (0.74603200000000003, 0.77777799999999997, 0.77777799999999997), (1.0, 1.0, 1.0)), 'red': ((0.0, 0.0, 0.0), (0.74603200000000003, 0.65277799999999997, 0.65277799999999997), (1.0, 1.0, 1.0))}, 'cool': {'blue': ((0.0, 1.0, 1.0), (1.0, 1.0, 1.0)), 'green': ((0.0, 1.0, 1.0), (1.0, 0.0, 0.0)), 'red': ((0.0, 0.0, 0.0), (1.0, 1.0, 1.0))}, 'copper': {'blue': ((0.0, 0.0, 0.0), (1.0, 0.4975, 0.4975)), 'green': ((0.0, 0.0, 0.0), (1.0, 0.78120000000000001, 0.78120000000000001)), 'red': ((0.0, 0.0, 0.0), (0.80952400000000002, 1.0, 1.0), (1.0, 1.0, 1.0))}, 'flag': {'blue': ((0.0, 0.0, 0.0), (0.015873000000000002, 1.0, 1.0), (0.031746000000000003, 1.0, 1.0), (0.047619000000000002, 0.0, 0.0), (0.063492000000000007, 0.0, 0.0), (0.079365000000000005, 1.0, 1.0), (0.095238000000000003, 1.0, 1.0), (0.111111, 0.0, 0.0), (0.12698400000000001, 0.0, 0.0), (0.14285700000000001, 1.0, 1.0), (0.15873000000000001, 1.0, 1.0), (0.17460300000000001, 0.0, 0.0), (0.19047600000000001, 0.0, 0.0), (0.206349, 1.0, 1.0), (0.222222, 1.0, 1.0), (0.238095, 0.0, 0.0), (0.25396800000000003, 0.0, 0.0), (0.269841, 1.0, 1.0), (0.28571400000000002, 1.0, 1.0), (0.30158699999999999, 0.0, 0.0), ...), 'green': ((0.0, 0.0, 0.0), (0.015873000000000002, 1.0, 1.0), (0.031746000000000003, 0.0, 0.0), (0.063492000000000007, 0.0, 0.0), (0.079365000000000005, 1.0, 1.0), (0.095238000000000003, 0.0, 0.0), (0.12698400000000001, 0.0, 0.0), (0.14285700000000001, 1.0, 1.0), (0.15873000000000001, 0.0, 0.0), (0.19047600000000001, 0.0, 0.0), (0.206349, 1.0, 1.0), (0.222222, 0.0, 0.0), (0.25396800000000003, 0.0, 0.0), (0.269841, 1.0, 1.0), (0.28571400000000002, 0.0, 0.0), (0.31746000000000002, 0.0, 0.0), (0.33333299999999999, 1.0, 1.0), (0.34920600000000002, 0.0, 0.0), (0.38095200000000001, 0.0, 0.0), (0.39682499999999998, 1.0, 1.0), ...), 'red': ((0.0, 1.0, 1.0), (0.015873000000000002, 1.0, 1.0), (0.031746000000000003, 0.0, 0.0), (0.047619000000000002, 0.0, 0.0), (0.063492000000000007, 1.0, 1.0), (0.079365000000000005, 1.0, 1.0), (0.095238000000000003, 0.0, 0.0), (0.111111, 0.0, 0.0), (0.12698400000000001, 1.0, 1.0), (0.14285700000000001, 1.0, 1.0), (0.15873000000000001, 0.0, 0.0), (0.17460300000000001, 0.0, 0.0), (0.19047600000000001, 1.0, 1.0), (0.206349, 1.0, 1.0), (0.222222, 0.0, 0.0), (0.238095, 0.0, 0.0), (0.25396800000000003, 1.0, 1.0), (0.269841, 1.0, 1.0), (0.28571400000000002, 0.0, 0.0), (0.30158699999999999, 0.0, 0.0), ...)}, 'gray': {'blue': ((0.0, 0, 0), (1.0, 1, 1)), 'green': ((0.0, 0, 0), (1.0, 1, 1)), 'red': ((0.0, 0, 0), (1.0, 1, 1))}, 'hot': {'blue': ((0.0, 0.0, 0.0), (0.74603200000000003, 0.0, 0.0), (1.0, 1.0, 1.0)), 'green': ((0.0, 0.0, 0.0), (0.36507899999999999, 0.0, 0.0), (0.74603200000000003, 1.0, 1.0), (1.0, 1.0, 1.0)), 'red': ((0.0, 0.041599999999999998, 0.041599999999999998), (0.36507899999999999, 1.0, 1.0), (1.0, 1.0, 1.0))}, 'hsv': {'blue': ((0.0, 0.0, 0.0), (0.33333299999999999, 0.0, 0.0), (0.34920600000000002, 0.0625, 0.0625), (0.50793699999999997, 1.0, 1.0), (0.84126999999999996, 1.0, 1.0), (0.85714299999999999, 0.9375, 0.9375), (1.0, 0.09375, 0.09375)), 'green': ((0.0, 0.0, 0.0), (0.15873000000000001, 0.9375, 0.9375), (0.17460300000000001, 1.0, 1.0), (0.50793699999999997, 1.0, 1.0), (0.66666700000000001, 0.0625, 0.0625), (0.68254000000000004, 0.0, 0.0), (1.0, 0.0, 0.0)), 'red': ((0.0, 1.0, 1.0), (0.15873000000000001, 1.0, 1.0), (0.17460300000000001, 0.96875, 0.96875), (0.33333299999999999, 0.03125, 0.03125), (0.34920600000000002, 0.0, 0.0), (0.66666700000000001, 0.0, 0.0), (0.68254000000000004, 0.03125, 0.03125), (0.84126999999999996, 0.96875, 0.96875), (0.85714299999999999, 1.0, 1.0), (1.0, 1.0, 1.0))}, 'jet': {'blue': ((0.0, 0.5, 0.5), (0.11, 1, 1), (0.34000000000000002, 1, 1), (0.65000000000000002, 0, 0), (1, 0, 0)), 'green': ((0.0, 0, 0), (0.125, 0, 0), (0.375, 1, 1), (0.64000000000000001, 1, 1), (0.91000000000000003, 0, 0), (1, 0, 0)), 'red': ((0.0, 0, 0), (0.34999999999999998, 0, 0), (0.66000000000000003, 1, 1), (0.89000000000000001, 1, 1), (1, 0.5, 0.5))}, 'pink': {'blue': ((0.0, 0.0, 0.0), (0.015873000000000002, 0.102869, 0.102869), (0.031746000000000003, 0.145479, 0.145479), (0.047619000000000002, 0.178174, 0.178174), (0.063492000000000007, 0.205738, 0.205738), (0.079365000000000005, 0.230022, 0.230022), (0.095238000000000003, 0.25197599999999998, 0.25197599999999998), (0.111111, 0.27216600000000002, 0.27216600000000002), (0.12698400000000001, 0.29095700000000002, 0.29095700000000002), (0.14285700000000001, 0.30860700000000002, 0.30860700000000002), (0.15873000000000001, 0.32529999999999998, 0.32529999999999998), (0.17460300000000001, 0.34117799999999998, 0.34117799999999998), (0.19047600000000001, 0.356348, 0.356348), (0.206349, 0.37089899999999998, 0.37089899999999998), (0.222222, 0.38490000000000002, 0.38490000000000002), (0.238095, 0.39840999999999999, 0.39840999999999999), (0.25396800000000003, 0.41147600000000001, 0.41147600000000001), (0.269841, 0.42413899999999999, 0.42413899999999999), (0.28571400000000002, 0.43643599999999999, 0.43643599999999999), (0.30158699999999999, 0.44839499999999999, 0.44839499999999999), ...), 'green': ((0.0, 0.0, 0.0), (0.015873000000000002, 0.102869, 0.102869), (0.031746000000000003, 0.145479, 0.145479), (0.047619000000000002, 0.178174, 0.178174), (0.063492000000000007, 0.205738, 0.205738), (0.079365000000000005, 0.230022, 0.230022), (0.095238000000000003, 0.25197599999999998, 0.25197599999999998), (0.111111, 0.27216600000000002, 0.27216600000000002), (0.12698400000000001, 0.29095700000000002, 0.29095700000000002), (0.14285700000000001, 0.30860700000000002, 0.30860700000000002), (0.15873000000000001, 0.32529999999999998, 0.32529999999999998), (0.17460300000000001, 0.34117799999999998, 0.34117799999999998), (0.19047600000000001, 0.356348, 0.356348), (0.206349, 0.37089899999999998, 0.37089899999999998), (0.222222, 0.38490000000000002, 0.38490000000000002), (0.238095, 0.39840999999999999, 0.39840999999999999), (0.25396800000000003, 0.41147600000000001, 0.41147600000000001), (0.269841, 0.42413899999999999, 0.42413899999999999), (0.28571400000000002, 0.43643599999999999, 0.43643599999999999), (0.30158699999999999, 0.44839499999999999, 0.44839499999999999), ...), 'red': ((0.0, 0.1178, 0.1178), (0.015873000000000002, 0.195857, 0.195857), (0.031746000000000003, 0.25066100000000002, 0.25066100000000002), (0.047619000000000002, 0.29546800000000001, 0.29546800000000001), (0.063492000000000007, 0.33432400000000001, 0.33432400000000001), (0.079365000000000005, 0.369112, 0.369112), (0.095238000000000003, 0.40089200000000003, 0.40089200000000003), (0.111111, 0.43033100000000002, 0.43033100000000002), (0.12698400000000001, 0.45788200000000001, 0.45788200000000001), (0.14285700000000001, 0.48386699999999999, 0.48386699999999999), (0.15873000000000001, 0.508525, 0.508525), (0.17460300000000001, 0.53204200000000001, 0.53204200000000001), (0.19047600000000001, 0.55456300000000003, 0.55456300000000003), (0.206349, 0.57620400000000005, 0.57620400000000005), (0.222222, 0.59706099999999995, 0.59706099999999995), (0.238095, 0.61721300000000001, 0.61721300000000001), (0.25396800000000003, 0.63672899999999999, 0.63672899999999999), (0.269841, 0.655663, 0.655663), (0.28571400000000002, 0.67406600000000005, 0.67406600000000005), (0.30158699999999999, 0.69198000000000004, 0.69198000000000004), ...)}, ...}<br>
<strong>flag</strong> = &lt;matplotlib.colors.LinearSegmentedColormap instance&gt;<br>
<strong>gray</strong> = &lt;matplotlib.colors.LinearSegmentedColormap instance&gt;<br>
<strong>hot</strong> = &lt;matplotlib.colors.LinearSegmentedColormap instance&gt;<br>
<strong>hsv</strong> = &lt;matplotlib.colors.LinearSegmentedColormap instance&gt;<br>
<strong>jet</strong> = &lt;matplotlib.colors.LinearSegmentedColormap instance&gt;<br>
<strong>nx</strong> = &lt;matplotlib.numerix._nc_imports._TypeNamespace instance&gt;<br>
<strong>pink</strong> = &lt;matplotlib.colors.LinearSegmentedColormap instance&gt;<br>
<strong>prism</strong> = &lt;matplotlib.colors.LinearSegmentedColormap instance&gt;<br>
<strong>rcParams</strong> = {'axes.edgecolor': 'k', 'axes.facecolor': 'w', 'axes.grid': False, 'axes.hold': True, 'axes.labelcolor': 'k', 'axes.labelsize': 12.0, 'axes.linewidth': 1.0, 'axes.titlesize': 14.0, 'backend': 'GTKAgg', 'datapath': '/usr/local/share/matplotlib', ...}<br>
<strong>spring</strong> = &lt;matplotlib.colors.LinearSegmentedColormap instance&gt;<br>
<strong>summer</strong> = &lt;matplotlib.colors.LinearSegmentedColormap instance&gt;<br>
<strong>verbose</strong> = &lt;matplotlib.Verbose instance&gt;<br>
<strong>winter</strong> = &lt;matplotlib.colors.LinearSegmentedColormap instance&gt;</td></tr></table>
@footer@
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.