擅长:python、mysql、java
<p>matplotlib文档页面上有很多关于自定义分段颜色条的示例资料</p>
<p>例如</p>
<blockquote>
<p><a href="http://matplotlib.org/examples/api/colorbar_only.html" rel="nofollow">http://matplotlib.org/examples/api/colorbar_only.html</a>
<a href="http://matplotlib.org/examples/pylab_examples/contourf_demo.html" rel="nofollow">http://matplotlib.org/examples/pylab_examples/contourf_demo.html</a></p>
</blockquote>
<p>编辑:</p>
<p>据我所知,这可能是您所要寻找的最佳示例:</p>
<blockquote>
<p><a href="http://matplotlib.org/examples/pylab_examples/custom_cmap.html" rel="nofollow">http://matplotlib.org/examples/pylab_examples/custom_cmap.html</a></p>
</blockquote>