Skip to content

Latest commit

 

History

History
46 lines (27 loc) · 1.49 KB

README.md

File metadata and controls

46 lines (27 loc) · 1.49 KB

cubehelix

A full implementation of Dave Green's cubehelix colormap for Python.

The user can adjust all parameters of the cubehelix algorithm. This enables much greater flexibility in choosing color maps, while (by default) ensuring the color map scales in brightness from black to white.

A few simple example flavors of cubehelix:

  • Default color map settings produce the standard "cubehelix": cubehelix.cmap()

Reversed Standard cubehelix scheme

  • Create color map in only blues: cubehelix.cmap(rot=0, start=0)
  • Create reverse (white to black) backwards through the rainbow once: cubehelix.cmap(rot=1, reverse=True)

A nice blue cubehelix scheme

a better rainbow

Discussion and examples shown on my blog: If We Assume

Basic Usage

import cubehelix
cx = cubehelix.cmap(start=0., rot=-0.5)
plot(x,cmap=cx)

Installation

Download:

  • Place cubehelix.py in your Python path.

From source::

setup.py install

or with pip::

pip install git+git://github.com/jradavenport/cubehelix.git