Pixie16 Analysis Software Suite
Analysis code for processing of .ldf files
|
Store the information for a trace. More...
#include <Trace.hpp>
Public Member Functions | |
Trace () | |
Trace (const std::vector< int > &x) | |
void | TrapezoidalFilter (Trace &filter, const TFP &parms, unsigned int lo=0) const |
void | TrapezoidalFilter (Trace &filter, const TFP &parms, unsigned int lo, unsigned int hi) const |
void | InsertValue (std::string name, double value) |
void | InsertValue (std::string name, int value) |
void | SetValue (std::string name, double value) |
void | SetValue (std::string name, int value) |
bool | HasValue (std::string name) const |
double | GetValue (std::string name) const |
std::vector< double > | GetWaveform () |
double | DoBaseline (unsigned int lo=0, unsigned int numBins=numBinsBaseline) |
double | DoDiscrimination (unsigned int lo, unsigned int numBins) |
double | DoQDC (unsigned int lo, unsigned int numBins) |
unsigned int | FindMaxInfo (unsigned int lo=5, unsigned int hi=10, unsigned int numBins=15) |
virtual void | DeclareHistogram1D (int dammId, int xSize, const char *title) |
Declares a 1D histogram calls the C++ wrapper for DAMM. More... | |
virtual void | DeclareHistogram2D (int dammId, int xSize, int ySize, const char *title) |
Declares a 2D histogram calls the C++ wrapper for DAMM. More... | |
virtual void | plot (int dammId, double val1, double val2=-1, double val3=-1, const char *name="h") const |
Implementation of the plot command to interface with the DAMM routines. More... | |
void | Plot (int id) |
void | Plot (int id, int row) |
void | ScalePlot (int id, double scale) |
void | ScalePlot (int id, int row, double scale) |
void | OffsetPlot (int id, double offset) |
void | OffsetPlot (int id, int row, double offset) |
Private Attributes | |
unsigned int | baselineLow |
low range for the baseline | |
unsigned int | baselineHigh |
high range for the baseline | |
std::vector< double > | waveform |
The waveform inside the trace. | |
std::map< std::string, double > | doubleTraceData |
Trace data stored as doubles. | |
std::map< std::string, int > | intTraceData |
Trace data stored as ints. | |
Static Private Attributes | |
static const unsigned int | numBinsBaseline = 15 |
Number of bins in the baseline. | |
static Plots | histo |
Store the information for a trace.
|
inline |
Default constructor
|
inline |
An automatic conversion for the trace
[in] | x | : the trace to store in the class |
|
inlinevirtual |
Declares a 1D histogram calls the C++ wrapper for DAMM.
[in] | dammId | : The histogram number to define |
[in] | xSize | : The range of the x-axis |
[in] | title | : The title for the histogram |
|
inlinevirtual |
Declares a 2D histogram calls the C++ wrapper for DAMM.
[in] | dammId | : The histogram number to define |
[in] | xSize | : The range of the x-axis |
[in] | ySize | : The range of the y-axis |
[in] | title | : The title of the histogram |
double Trace::DoBaseline | ( | unsigned int | lo = 0 , |
unsigned int | numBins = numBinsBaseline |
||
) |
Performs the baseline calculation
[in] | lo | : the low range for the baseline calculation |
[in] | numBins | : The number of bins for the baseline calculation |
double Trace::DoDiscrimination | ( | unsigned int | lo, |
unsigned int | numBins | ||
) |
Performs the neutron-gamma discrimination on the traces
[in] | lo | : The low range for the discrimination (referenced from max) |
[in] | numBins | : the number of bins to calculate the baseline over |
double Trace::DoQDC | ( | unsigned int | lo, |
unsigned int | numBins | ||
) |
Calculate the waveform and QDC for the trace
[in] | lo | : the lo value to for the QDC |
[in] | numBins | : the number of bins to calculate the QDC over |
unsigned int Trace::FindMaxInfo | ( | unsigned int | lo = 5 , |
unsigned int | hi = 10 , |
||
unsigned int | numBins = 15 |
||
) |
Calculate information for the maximum value of the trace
[in] | lo | : the low side of the waveform |
[in] | hi | : the high side of the waveform |
[in] | numBins | : the number of bins to look for the max in |
|
inline |
Returns the value of the requested parameter
[in] | name | : the name of the parameter to get for |
|
inline |
|
inline |
Checks to see if a parameter has a value
[in] | name | : the name of the parameter to check for |
|
inline |
Insert a value into the trace map
[in] | name | : the name of the parameter to insert |
[in] | value | : the value to insert into the map |
|
inline |
Insert an int value into the trace
[in] | name | : the name of the variable to insert |
[in] | value | : The integer value to insert into the map |
void Trace::OffsetPlot | ( | int | id, |
double | offset | ||
) |
plot trace with a vertical offset in a 1D histogram
[in] | id | : histogram ID to plot into |
[in] | offset | : the offset for the trace |
void Trace::OffsetPlot | ( | int | id, |
int | row, | ||
double | offset | ||
) |
plot trace with a vertical offset in a 2D histogram
[in] | id | : histogram ID to plot into |
[in] | row | : the row to plot the trace into |
[in] | offset | : the offset for the trace |
|
inlinevirtual |
Implementation of the plot command to interface with the DAMM routines.
This is also done in the EventProcessor class, redundant?
[in] | dammId | : The histogram number to plot into |
[in] | val1 | : The x value to plot |
[in] | val2 | : The y value to plot (if 2D histogram) |
[in] | val3 | : The z value to plot (if 2D histogram) |
[in] | name | : The name of the histogram |
void Trace::Plot | ( | int | id | ) |
plot trace into a 1D histogram
[in] | id | : histogram ID to plot into |
void Trace::Plot | ( | int | id, |
int | row | ||
) |
plot trace into row of a 2D histogram
[in] | id | : histogram ID to plot into |
[in] | row | : the row to plot into |
void Trace::ScalePlot | ( | int | id, |
double | scale | ||
) |
plot trace absolute value and scaled into a 1D histogram
[in] | id | : histogram ID to plot into |
[in] | scale | : the scaling for the trace |
void Trace::ScalePlot | ( | int | id, |
int | row, | ||
double | scale | ||
) |
plot trace absolute value and scaled into a 2D histogram
[in] | id | : histogram ID to plot into |
[in] | row | : the row to plot the histogram into |
[in] | scale | : the scaling for the trace |
|
inline |
Set the double value of a parameter in the trace
[in] | name | : the name of the parameter to set |
[in] | value | : the double value to set the parameter to |
|
inline |
Set the integer value of a parameter in the trace
[in] | name | : the name of the parameter to set |
[in] | value | : the int value to set the parameter to |
|
inline |
calculation of the trapezoidal filter
[in] | filter | : the filter for the trace |
[in] | parms | : the parameters for the filter |
[in] | lo | : the low range for the filter |
void Trace::TrapezoidalFilter | ( | Trace & | filter, |
const TFP & | parms, | ||
unsigned int | lo, | ||
unsigned int | hi | ||
) | const |
Defines how to implement a trapezoidal filter characterized by two moving sum windows of width risetime separated by a length gaptime. Filter is calculated from channels lo to hi.
[in] | filter | : the filter for the trace |
[in] | parms | : the parameters for the filter |
[in] | lo | : the low range for the filter |
[in] | hi | : the high range for the filter |
|
staticprivate |
This field is static so all instances of Trace class have access to the same plots and plots range.