#include <XHistogram.h>
Classes | |
struct | position |
Public Types | |
typedef TH2I | ColorMap |
typedef TH2F | Histogram |
typedef std::pair< double, double > | Range |
Public Member Functions | |
ColorMap * | colormap (void) const |
access the colormap More... | |
void | fill (double x, double y, const std::vector< double > &weight, double norm) |
fill one point More... | |
void | fill (double x, double y, const std::vector< double > &weight, double norm, unsigned int colour) |
fill one point and set its color More... | |
void | fill (const Range &x, const Range &y, const std::vector< double > &weight, double norm) |
fill one segment, normalizing each bin's weight to the fraction of the segment it contains More... | |
void | fill (const Range &x, const Range &y, const std::vector< double > &weight, double norm, unsigned int colour) |
fill one segment and set its color, normalizing each bin's weight to the fraction of the segment it contains More... | |
Histogram * | get (size_t h=0) const |
access one of the histograms More... | |
Histogram * | normalization (void) const |
access the normalization More... | |
void | normalize (void) |
normalize the histograms More... | |
void | setMinDl (double dl) |
XHistogram (void) | |
default CTOR More... | |
XHistogram (size_t size, size_t bins_x, size_t bins_y, Range x, Range y, size_t zones, std::vector< double > max) | |
Protected Member Functions | |
void | check_weight (const std::vector< double > &weight) throw (std::invalid_argument) |
check the weights passed as an std::vector have the correct size More... | |
std::vector< position > | splitSegment (Range x, Range y) const |
split a segment into a vector of points More... | |
Protected Attributes | |
boost::shared_ptr< ColorMap > | m_colormap |
boost::shared_ptr< Histogram > | m_dummy |
std::vector< boost::shared_ptr < Histogram > > | m_histograms |
double | m_minDl |
boost::shared_ptr< Histogram > | m_normalization |
size_t | m_size |
size_t | m_xBins |
Range | m_xRange |
size_t | m_yBins |
Range | m_yRange |
Definition at line 13 of file XHistogram.h.
typedef TH2I XHistogram::ColorMap |
Definition at line 16 of file XHistogram.h.
typedef TH2F XHistogram::Histogram |
Definition at line 17 of file XHistogram.h.
typedef std::pair<double, double> XHistogram::Range |
Definition at line 18 of file XHistogram.h.
|
inline |
default CTOR
Definition at line 35 of file XHistogram.h.
|
inline |
Definition at line 49 of file XHistogram.h.
References i, m_colormap, m_histograms, m_normalization, and m_size.
|
inlineprotected |
check the weights passed as an std::vector have the correct size
Definition at line 135 of file XHistogram.h.
References m_size, and CommonMethods::weight().
Referenced by fill().
|
inline |
access the colormap
Definition at line 104 of file XHistogram.h.
References m_colormap.
Referenced by TrackingMaterialPlotter::draw().
void XHistogram::fill | ( | double | x, |
double | y, | ||
const std::vector< double > & | weight, | ||
double | norm | ||
) |
fill one point
Definition at line 71 of file XHistogram.cc.
References check_weight(), HcalObjRepresent::Fill(), h, m_histograms, m_normalization, and m_size.
Referenced by TrackingMaterialPlotter::plotSegmentInLayer(), and TrackingMaterialPlotter::plotSegmentUnassigned().
void XHistogram::fill | ( | double | x, |
double | y, | ||
const std::vector< double > & | weight, | ||
double | norm, | ||
unsigned int | colour | ||
) |
fill one point and set its color
Definition at line 81 of file XHistogram.cc.
References check_weight(), HcalObjRepresent::Fill(), h, m_colormap, m_histograms, m_normalization, and m_size.
void XHistogram::fill | ( | const Range & | x, |
const Range & | y, | ||
const std::vector< double > & | weight, | ||
double | norm | ||
) |
fill one segment, normalizing each bin's weight to the fraction of the segment it contains
Definition at line 92 of file XHistogram.cc.
References check_weight(), f, HcalObjRepresent::Fill(), h, i, m_histograms, m_normalization, m_size, alignCSCRings::s, splitSegment(), and v.
void XHistogram::fill | ( | const Range & | x, |
const Range & | y, | ||
const std::vector< double > & | weight, | ||
double | norm, | ||
unsigned int | colour | ||
) |
fill one segment and set its color, normalizing each bin's weight to the fraction of the segment it contains
Definition at line 105 of file XHistogram.cc.
References check_weight(), f, HcalObjRepresent::Fill(), h, i, m_colormap, m_histograms, m_normalization, m_size, alignCSCRings::s, splitSegment(), and v.
|
inline |
access one of the histograms
Definition at line 89 of file XHistogram.h.
References h, m_histograms, and m_size.
Referenced by Options.Options::__getitem__(), betterConfigParser.BetterConfigParser::__updateDict(), TrackingMaterialPlotter::draw(), betterConfigParser.BetterConfigParser::getCompares(), betterConfigParser.BetterConfigParser::getGeneral(), and betterConfigParser.BetterConfigParser::getResultingSection().
|
inline |
access the normalization
Definition at line 98 of file XHistogram.h.
References m_normalization.
void XHistogram::normalize | ( | void | ) |
normalize the histograms
Definition at line 119 of file XHistogram.cc.
References h, i, m_histograms, m_normalization, and m_size.
Referenced by TrackingMaterialPlotter::normalize().
|
inline |
set the minimum length of sub-segment a segment should be split into: when splitting across bin boundaries with splitSegment(...), sub-segments shorter than this are skipped
Definition at line 111 of file XHistogram.h.
References m_minDl.
|
protected |
split a segment into a vector of points
Definition at line 7 of file XHistogram.cc.
References f, i, m_minDl, m_xBins, m_xRange, m_yBins, m_yRange, position, query::result, alignCSCRings::s, python.multivaluedict::sort(), relval_steps::steps, v, vdt::x, and detailsBasic3DVector::y.
Referenced by fill().
|
protected |
Definition at line 30 of file XHistogram.h.
Referenced by colormap(), fill(), and XHistogram().
|
protected |
Definition at line 31 of file XHistogram.h.
|
protected |
Definition at line 28 of file XHistogram.h.
Referenced by fill(), get(), normalize(), and XHistogram().
|
protected |
Definition at line 21 of file XHistogram.h.
Referenced by setMinDl(), and splitSegment().
|
protected |
Definition at line 29 of file XHistogram.h.
Referenced by fill(), normalization(), normalize(), and XHistogram().
|
protected |
Definition at line 26 of file XHistogram.h.
Referenced by check_weight(), fill(), get(), normalize(), and XHistogram().
|
protected |
Definition at line 24 of file XHistogram.h.
Referenced by splitSegment().
|
protected |
Definition at line 22 of file XHistogram.h.
Referenced by splitSegment().
|
protected |
Definition at line 25 of file XHistogram.h.
Referenced by splitSegment().
|
protected |
Definition at line 23 of file XHistogram.h.
Referenced by splitSegment().