Skip to content

Latest commit

 

History

History
34 lines (23 loc) · 914 Bytes

README.md

File metadata and controls

34 lines (23 loc) · 914 Bytes

mpl-interact

PyPI version Build status Docs status License

A library encompassing smart interactions missing in matplotlib

UNDER DEVELOPMENT

Usage

The following code enables interactors for GCF:

  • zoom by mouse wheel scrolling
  • drag by mouse left button
  • reset by mouse any button double click
import numpy as np
from matplotlib import pyplot as plt
from mpl_interact import interact

x = np.linspace(0, 2*np.pi, 100)
ys = np.sin(x)
yc = np.cos(x)

plt.plot(x, ys, 'o-', x, yc, 'o-')

interact()

plt.show()