Skip to content

Commit

Permalink
Merge pull request #18 from CJ-Wright/waterfall_callback
Browse files Browse the repository at this point in the history
Waterfall callback
  • Loading branch information
CJ-Wright authored Aug 28, 2017
2 parents 869a78e + 56915ca commit 338c1bd
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions xpdview/callbacks.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from bluesky.callbacks.broker import BrokerCallbackBase
from .waterfall import Waterfall
import matplotlib.pyplot as plt


class LiveWaterfall(BrokerCallbackBase):
Expand All @@ -25,11 +26,11 @@ def __init__(self, x_name, y_name, db=None, units=None):
self.y_name = y_name
self.units = units

from matplotlib.figure import Figure
self.fig = Figure()
self.fig = plt.figure()

self.wf = Waterfall(fig=self.fig, unit=self.units)
self.i = 0
self.fig.show()

def start(self, doc):
self.i = 0
Expand Down

0 comments on commit 338c1bd

Please sign in to comment.