Skip to content

matplotlib/mpl-probscale

Repository files navigation

mpl-probscale

Real probability scales for matplotlib

Build Status Coverage Status

Sphinx Docs

Installation

conda install mpl-probscale --channel=phobson

Quick start

Simply importing probscale lets you use probability scales in your matplotlib figures:

import matplotlib.pyplot as plt
import probscale
import seaborn
clear_bkgd = {'axes.facecolor':'none', 'figure.facecolor':'none'}
seaborn.set(style='ticks', context='notebook', rc=clear_bkgd)

fig, ax = plt.subplots(figsize=(8, 4))
ax.set_ylim(1e-2, 1e2)
ax.set_yscale('log')

ax.set_xlim(0.5, 99.5)
ax.set_xscale('prob')
seaborn.despine(fig=fig)

Alt text

Testing

Testing is generally done via the nose and numpy.testing modules. The best way to run the tests is in an interactive python session:

import matplotlib
matplotib.use('agg')
import probscale
probscale.test()