Skip to main content

A simple library for plotting lines with color gradients

Project description

rainbowline

A simple library for plotting lines with color gradients in matplotlib.

Example plot

Usage

The function rainbow_line() has the following arguments:

  • x: the x values to plot
  • y: the y values to plot
  • c: the values to map to a color using the specified cmap. If not provided, the index of x or y will be used if possible.
  • cmap: (optional) colormap to apply to the c values. Defaults to 'jet'.
  • norm: (optional) normalization for c values. If not given, the min and max values of c will be used. One of the following:
    • matplotlib norm object.
    • float or int: in this case, values will be normalized to the range (0, norm)
    • tuple defining the min and max values to which to normalize
  • ax: (optional) matplotlib Axes object on which to plot
  • autoscale_view: whether to scale the axes to the extents of the plot. Default True.
  • **kwargs: (optional) kwargs which will be passed to matplotlib LineCollection constructor.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

rainbowline-0.0.1.tar.gz (57.8 kB view details)

Uploaded Source

Built Distribution

rainbowline-0.0.1-py3-none-any.whl (4.2 kB view details)

Uploaded Python 3

File details

Details for the file rainbowline-0.0.1.tar.gz.

File metadata

  • Download URL: rainbowline-0.0.1.tar.gz
  • Upload date:
  • Size: 57.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.8.8

File hashes

Hashes for rainbowline-0.0.1.tar.gz
Algorithm Hash digest
SHA256 02b402472d763a48b2ffd88f387e974b5340f5e94ac257144e18004080b51ee0
MD5 0648e71e11d92f8c44a9b2d2a1df1da4
BLAKE2b-256 74b5fd14cea51bf7ce76b8c09a23c72d7017d4d7ef84b02c2043a70f1bd25f8a

See more details on using hashes here.

File details

Details for the file rainbowline-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: rainbowline-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 4.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.8.8

File hashes

Hashes for rainbowline-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 b734802350e796fe7799d3ef0be41966595536d9d3f860079db3f7192aaaf936
MD5 7584c1e1e8213fc90df35b9d24322b5d
BLAKE2b-256 078e274094745cf38263f326f08725efe11e163c37de882fded18939e0e3bcb9

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page