GSI Object Oriented Online Offline (Go4) GO4-6.4.0
|
Graphs that renew themselves iteratively to monitor a value. More...
#include <TGo4RollingGraph.h>
Public Member Functions | |
TGo4RollingGraph () | |
Default constructor. | |
TGo4RollingGraph (Int_t NumPoints, Int_t UpdateInterval=1) | |
Constructor with size and update interval. | |
virtual | ~TGo4RollingGraph () |
Destructor. | |
void | Clear (Option_t *option="") override |
Clear all points. | |
virtual void | Fill (Double_t value, Double_t xerror=-1, Double_t yerror=-1) |
Fills a new value into the rolling graph. | |
Int_t | GetNumPoints () const |
Returns number of displayed points. | |
Int_t | GetUpdateInterval () const |
Returns interval of entries when a new bin is opened. | |
Protected Member Functions | |
ClassDefOverride (TGo4RollingGraph, 1) | |
void | NextBin () |
Create a new bin. | |
Protected Attributes | |
Double_t | fdSum {0} |
Summed total value in the current Bin. | |
Double_t | fdSumAveraged {0} |
Averaged summed total value in the current Bin. | |
Long64_t | fiCounter {0} |
No. of values filled in total. | |
Int_t | fiNumPoints {0} |
Nominal size of the graph, i.e. number of points to display. | |
Int_t | fiUpdateInterval {0} |
Number of Fill() functions to call before a new average is started. | |
Graphs that renew themselves iteratively to monitor a value.
As old points are to be deleted at a certain point, this has the appearance of a rolling counter.
Definition at line 24 of file TGo4RollingGraph.h.
TGo4RollingGraph::TGo4RollingGraph | ( | ) |
Default constructor.
Creates a rolling graph with an update interval of 1, i.e. no averaging of the input values Graph will have no size, either. Without setting size, nothing will be drawn!
Definition at line 23 of file TGo4RollingGraph.cxx.
References fdSum, fdSumAveraged, fiCounter, fiNumPoints, and fiUpdateInterval.
Referenced by ClassDefOverride().
TGo4RollingGraph::TGo4RollingGraph | ( | Int_t | NumPoints, |
Int_t | UpdateInterval = 1 ) |
Constructor with size and update interval.
NumPoints | Size of the graph, i.e. number of points |
UpdateInterval | No. of calls to the Fill() routine after which a new bin will started to be filled. For UpdateInterval=1 every value will be displayed directly on the rolling graph, for values > 1 an average will be shown |
Definition at line 33 of file TGo4RollingGraph.cxx.
References fdSum, fdSumAveraged, fiCounter, fiNumPoints, and fiUpdateInterval.
|
virtual |
Destructor.
Definition at line 40 of file TGo4RollingGraph.cxx.
|
protected |
References TGo4RollingGraph().
|
override |
Clear all points.
Remove all points from the graph, set number of points to zero, and reset internal value for averaging
Definition at line 106 of file TGo4RollingGraph.cxx.
References fdSum, and fiNumPoints.
|
virtual |
Fills a new value into the rolling graph.
value | The value to fill |
xerror | The X value |
yerror | The Y value |
If the Update Interval is larger than one, the value will not be displayed directly in the graph but added to the averaging
Definition at line 51 of file TGo4RollingGraph.cxx.
References fdSum, fdSumAveraged, fiCounter, fiNumPoints, fiUpdateInterval, and NextBin().
|
inline |
Returns number of displayed points.
Definition at line 35 of file TGo4RollingGraph.h.
References fiNumPoints.
|
inline |
Returns interval of entries when a new bin is opened.
Definition at line 36 of file TGo4RollingGraph.h.
References fiUpdateInterval.
|
protected |
Create a new bin.
Internal function that implements the "rolling" of the graph: The first bin is deleted while a new one is appended at the end
Definition at line 82 of file TGo4RollingGraph.cxx.
References fiNumPoints.
Referenced by Fill().
|
protected |
Summed total value in the current Bin.
Definition at line 44 of file TGo4RollingGraph.h.
Referenced by TGo4RollingGraph(), TGo4RollingGraph(), Clear(), and Fill().
|
protected |
Averaged summed total value in the current Bin.
Definition at line 45 of file TGo4RollingGraph.h.
Referenced by TGo4RollingGraph(), TGo4RollingGraph(), and Fill().
|
protected |
No. of values filled in total.
Definition at line 43 of file TGo4RollingGraph.h.
Referenced by TGo4RollingGraph(), TGo4RollingGraph(), and Fill().
|
protected |
Nominal size of the graph, i.e. number of points to display.
Definition at line 41 of file TGo4RollingGraph.h.
Referenced by TGo4RollingGraph(), TGo4RollingGraph(), Clear(), Fill(), GetNumPoints(), and NextBin().
|
protected |
Number of Fill() functions to call before a new average is started.
Definition at line 42 of file TGo4RollingGraph.h.
Referenced by TGo4RollingGraph(), TGo4RollingGraph(), Fill(), and GetUpdateInterval().