class Trace: def __init__(self, descrStr): self.descr = descrStr self.x = None self.xlabel = None self.xunit = None self.y = None self.ylabel = None self.yunit = None def plot(self): import matplotlib.pyplot as plt plt.plot(self.x, self.y, label=self.descr) plt.legend()