Berkeley Nuclear Data Software
WFPlotter.h
Go to the documentation of this file.
1 #ifndef _WF_PLOTTER_H_
2 #define _WF_PLOTTER_H_
3 
4 #include "TGraph.h"
5 #include "TMultiGraph.h"
6 #include "TArrayS.h"
7 
8 #include <iostream>
9 
10 class WFPlotter
11 {
12 public:
13  WFPlotter();
15  template <class T> void addGraph(std::vector<T> a_wfYs);
16  void addGraph(TArrayS& a_array);
21  void addInvertedGraph(TArrayS& a_array,int a_norm=0);
22  template <class T> TGraph* getGraph(std::vector<T> a_wfYs);
23  TGraph* getGraph(TArrayS& a_array);
24  TGraph* getInvertedGraph(TArrayS& a_array,int a_norm=0);
26  TMultiGraph* getMG();
27  void drawState();
28  void clearState();
29 private:
31  TMultiGraph* m_graphs;
32  std::vector<int> m_lineColors;
33  int m_currentColor;
34 };
35 
36 #include "WFPlotter.hpp"
37 #endif
Definition: WFPlotter.h:11
TGraph * getGraph(std::vector< T > a_wfYs)
Definition: WFPlotter.hpp:20
void clearState()
Definition: WFPlotter.cpp:24
WFPlotter()
Definition: WFPlotter.cpp:5
void drawState()
Definition: WFPlotter.cpp:19
void addGraph(std::vector< T > a_wfYs)
adds the supplied vector to the graph
Definition: WFPlotter.hpp:7
TMultiGraph * getMG()
!!!!!!!!!CUIRRENTLY BREAKS ENCAPSULATION NEEDS TO CLONE!!!!!!!!!!
Definition: WFPlotter.cpp:14
void addInvertedGraph(TArrayS &a_array, int a_norm=0)
Definition: WFPlotter.cpp:39
TGraph * getInvertedGraph(TArrayS &a_array, int a_norm=0)
Definition: WFPlotter.cpp:61