matplotlib.use('tkagg') code example Example: interative mode matplotlib import matplotlib.pyplot as plt plt.ion() plt.plot([1.6, 2.7])