Cat
Functions
A3PE_BitFlip Namespace Reference

Functions

def Edit (cat, obj, panel, path)
 
def Plot (cat, obj, parent, id)
 

Function Documentation

◆ Edit()

def A3PE_BitFlip.Edit (   cat,
  obj,
  panel,
  path 
)

Definition at line 20 of file A3PE_BitFlip.py.

20 def Edit (cat, obj, panel, path):
21  return A3PE_BitFlip(cat, obj, panel, path)
22 
23 #----------------------------------------------------------------------
24 
def Edit(cat, obj, panel, path)
Definition: A3PE_BitFlip.py:20

◆ Plot()

def A3PE_BitFlip.Plot (   cat,
  obj,
  parent,
  id 
)

Definition at line 25 of file A3PE_BitFlip.py.

References plotter.h1d(), and Object.title().

25 def Plot(cat, obj, parent, id):
26  from mpl_toolkits.mplot3d import Axes3D
27  from matplotlib import cm
28  import matplotlib as mpl
29  import matplotlib.pyplot as plt
30  import numpy as np
31 
32  plot=plotter(parent,id)
33  fig=plot.current()
34  fig.suptitle('A3PE Bit Flip - Results', fontsize=14, fontweight='bold')
35 
36  # plot histo root
37  p1=fig.add_subplot(3,1,1)
38  h1=h1d(p1, obj.hist1d(0), facecolor='green',linestyle='dashed')
39  p1.set_title(obj.hist1d(0).title())
40  p1.grid(True)
41 
42  # plot histo root
43  p2=fig.add_subplot(3,1,2)
44  h2=obj.hist1d(1)
45  print h2.xbins()
46  p2.plot(h2.xbins(),h2.bins(),'ro',color='red')
47  p2.set_title(obj.hist1d(1).title())
48  p2.grid(False)
49 
50  # plot histo root
51  p3=fig.add_subplot(3,1,3)
52  h3=h1d(p3, obj.hist1d(2))
53  p3.set_title(obj.hist1d(2).title())
54  p3.grid(True)
55 
56  # return the plot that must be plotted
57  return plot
58 
def h1d(fig, histo, alpha=0.5, facecolor='green', edgecolor='yellow', linestyle='dashed')
Definition: plotter.py:51
def Plot(cat, obj, parent, id)
Definition: A3PE_BitFlip.py:25