示例#1
0
 def test_plot(self):
     """
     Test that plot is created with various arguments.
     """
     tf = TransitiveFingerprint(axl.TitForTat)
     tf.fingerprint(turns=10, repetitions=2, progress_bar=False)
     p = tf.plot()
     self.assertIsInstance(p, matplotlib.pyplot.Figure)
     p = tf.plot(cmap="jet")
     self.assertIsInstance(p, matplotlib.pyplot.Figure)
     p = tf.plot(interpolation="bicubic")
     self.assertIsInstance(p, matplotlib.pyplot.Figure)
     p = tf.plot(title="Title")
     self.assertIsInstance(p, matplotlib.pyplot.Figure)
     p = tf.plot(colorbar=False)
     self.assertIsInstance(p, matplotlib.pyplot.Figure)
     p = tf.plot(labels=False)
     self.assertIsInstance(p, matplotlib.pyplot.Figure)
     p = tf.plot(display_names=True)
     self.assertIsInstance(p, matplotlib.pyplot.Figure)
示例#2
0
 def test_plot(self):
     """
     Test that plot is created with various arguments.
     """
     tf = TransitiveFingerprint(axl.TitForTat)
     tf.fingerprint(turns=10, repetitions=2, progress_bar=False)
     p = tf.plot()
     self.assertIsInstance(p, matplotlib.pyplot.Figure)
     p = tf.plot(cmap="jet")
     self.assertIsInstance(p, matplotlib.pyplot.Figure)
     p = tf.plot(interpolation="bicubic")
     self.assertIsInstance(p, matplotlib.pyplot.Figure)
     p = tf.plot(title="Title")
     self.assertIsInstance(p, matplotlib.pyplot.Figure)
     p = tf.plot(colorbar=False)
     self.assertIsInstance(p, matplotlib.pyplot.Figure)
     p = tf.plot(labels=False)
     self.assertIsInstance(p, matplotlib.pyplot.Figure)
     p = tf.plot(display_names=True)
     self.assertIsInstance(p, matplotlib.pyplot.Figure)
示例#3
0
 def test_plot_with_axis(self):
     fig, axarr = matplotlib.pyplot.subplots(2, 2)
     tf = TransitiveFingerprint(axl.TitForTat)
     tf.fingerprint(turns=10, repetitions=2, progress_bar=False)
     p = tf.plot(ax=axarr[0, 0])
     self.assertIsInstance(p, matplotlib.pyplot.Figure)
示例#4
0
 def test_plot_with_axis(self):
     fig, axarr = matplotlib.pyplot.subplots(2, 2)
     tf = TransitiveFingerprint(axl.TitForTat)
     tf.fingerprint(turns=10, repetitions=2, progress_bar=False)
     p = tf.plot(ax=axarr[0, 0])
     self.assertIsInstance(p, matplotlib.pyplot.Figure)