ATLAS Offline Software
|
#include <Resplot.h>
Classes | |
class | ResException |
Public Member Functions | |
Resplot () | |
Resplot (const std::string &name, int n1, double a1, double b1, int n2, double a2, double b2, const std::string &xaxis="") | |
Resplot (const std::string &name, int n1, const double *a1, int n2, double a2, double b2, const std::string &xaxis="") | |
Resplot (const std::string &name, const std::vector< double > &a, int n2, double a2, double b2, const std::string &xaxis="") | |
Resplot (const std::string &name, const std::vector< double > &a, const std::vector< double > &b, const std::string &xaxis="") | |
Resplot (const Resplot &r, const std::string &tag="") | |
Resplot (const std::string &name, const TH2 *hin, const bool flip=false) | |
Resplot (const std::string &name) | |
virtual | ~Resplot () |
void | Initialise (const std::string &name, int n1, double a1, double b1, int n2, double a2, double b2) |
void | Initialise (const std::string &name, int n1, const double *a1, int n2, double a2, double b2) |
void | Initialise (const std::string &name, int n1, const double *a1, int n2, const double *a2) |
void | Initialise (const std::string &name, const std::vector< double > &a, int n2, double a2, double b2) |
void | Initialise (const std::string &name, const std::vector< double > &a, const std::vector< double > &b) |
int | Fill (double x, double y, double w=1) |
StatVal | GetEfficiency (TH1D *h, double lower, double upper) |
StatVal | GetGlobalEfficiency (double lower, double upper) |
TH1D * | GetEfficiencies (const std::string &hname, double lower, double upper) |
TH1D * | GetEfficiencies (const std::string &hname, double Nsigma) |
void | SetXAxis (const std::string &xaxis) |
void | SetYAxis (const std::string &yaxis) |
std::vector< double > | GetPrimaryLimits () const |
std::vector< double > | GetPrimaryCentres () const |
const std::string & | Name () const |
const std::string & | Name (const std::string &s) |
TH1D * | Mean () |
const TH1D * | Mean () const |
TH1D * | Sigma () |
TH1D * | Chi2 () |
const TH1D * | Chi2 () const |
TH1D * | H1D () |
const TH1D * | H1D () const |
TH2D * | H2D () |
const TH2D * | H2D () const |
TH1D * | Uncertainty () |
const TH1D * | Uncertainty () const |
bool | finalised () const |
const std::vector< TH1D * > & | Slices () const |
const std::string & | FitName () const |
int | Finalise (double a=-999, double b=-999, TF1 *(*func)(TH1D *s, double a, double b)=Resplot::FitGaussian) |
int | Finalise (TF1 *(*func)(TH1D *s, double a, double b), double a=-999, double b=-999) |
int | Fit (TF1 *(*func)(TH1D *s, double a, double b)) |
int | Refit (TF1 *(*func)(TH1D *s, double a, double b)) |
TDirectory * | Dir () |
Int_t | Write (const char *=0, Int_t=0, Int_t=0) const |
Hooray, this stupidity is to overwride both the const and non-const TObject Write methods Fixme: should probably remove all of these so root can write out using the dictionary but I could never get that to work. More... | |
Int_t | Write (const char *=0, Int_t=0, Int_t=0) |
Int_t | DWrite (TDirectory *g=0) const |
boooo, need to use the stupid Int_t class because I foolishly gave this function the same name as TObject::Write More... | |
void | SetDirectory (TDirectory *=0) |
Resplot & | operator+= (const Resplot &r) |
operators More... | |
Resplot & | operator*= (double d) |
Resplot | operator* (double d) const |
Resplot | operator+ (const Resplot &r) const |
void | Integrate () |
void | setUniform (bool t=false) |
Static Public Member Functions | |
static TF1 * | FitInternal (TH1D *s, double a=-999, double b=-999, TF1 *f1=0) |
static TF1 * | FitGaussian (TH1D *s, double a=-999, double b=-999) |
static TF1 * | FitRGaussian (TH1D *s, double a=-999, double b=-999) |
static TF1 * | FitBreit (TH1D *s, double a=-999, double b=-999) |
static TF1 * | FitRBreit (TH1D *s, double a=-999, double b=-999) |
static TF1 * | FitATan (TH1D *s, double a=-999, double b=-999) |
static TF1 * | FitNull (TH1D *s, double a=-999, double b=-999) |
static TF1 * | FitPoisson (TH1D *s, double a=-999, double b=-999) |
static TF1 * | FitXExp (TH1D *s, double a=-999, double b=-999) |
static TF1 * | FitLandauGauss (TH1D *s, double a=-999, double b=-999) |
static TF1 * | FitCentralGaussian (TH1D *s, double a=-999, double b=-999) |
static TF1 * | FitNull95 (TH1D *s, double a=0, double b=0) |
static TF1 * | FitNull95New (TH1D *s, double frac=0.95, bool useroot=false) |
static TF1 * | FitNull95Obsolete (TH1D *s, double frac=0.95, bool useroot=false) |
static TF1 * | FitNull95Central (TH1D *s) |
static bool | AddDirectoryStatus () |
static void | AddDirectory (bool t=false) |
static void | setInterpolateFlag (bool b) |
static const std::string & | version () |
static bool | setoldrms95 (bool b) |
static bool | setscalerms95 (bool b) |
static bool | setnofit (bool b) |
static TH2D * | rotate (const TH2 *h) |
flip the x and y axes More... | |
static TH2D * | combine (const TH2 *h, double x, int N) |
combine bins along the x axis after value x, combine each N bins into a single bin More... | |
static TH1D * | combine (const TH1 *h, double x, int N) |
after value x, combine each N bins into a single bin More... | |
static TH2D * | combine (const TH2 *h, double epsilon) |
combine bins along the x axis combine bins such that the stat precision is better than epsilon More... | |
static TH1D * | combine (const TH1 *h, double epsilon) |
combine bins in a 2D histogram it takes a value, x and all the bins with BinLowEdge > x get combined N bins at a time. More... | |
static std::vector< double > | findbins (const TH1 *h, double epsilon) |
static TH1D * | rebin (const TH1 *h, const std::vector< double > &bins) |
static std::vector< double > | getbins (const TH1 *h) |
Private Types | |
enum | ERROR { OK, HISTOWIDTH, BINWIDTH, EMPTY } |
Private Member Functions | |
void | MakeSlices () |
void | skip (TH1D *t) |
void | delskip (TH1D *t) |
void | deletehist (TH1D *t) |
void | skip (TH2D *t) |
void | delskip (TH2D *t) |
void | deletehist (TH2D *t) |
void | SetPrimary (int n, const double *) |
void | SetPrimary (int n, double, double) |
void | SetSecondary (int n, double a, double b) |
StatVal | get_mean () |
StatVal | get_sigma () |
void | AddEfficiency (TH1D *h, int i, double lower, double upper) |
void | AddResolution (TH1D *h, int i) |
void | AddMean (TH1D *h, int i) |
void | clear () |
Private Attributes | |
bool | m_Set |
std::string | m_name |
TH1D * | m_Nentries = 0 |
TH1D * | m_mean = 0 |
TH1D * | m_sigma = 0 |
TH1D * | m_chi2 = 0 |
TH2D * | m_h2d = 0 |
TH1D * | m_h1d = 0 |
StatVal | m_g_mean |
StatVal | m_g_sigma |
TDirectory * | m_dir = 0 |
int | m_n_primary |
int | m_n_secondary |
double | m_a_secondary |
double | m_b_secondary |
std::string | m_xaxis |
std::string | m_yaxis |
std::vector< TH1D * > | m_slices |
std::string | m_fitname |
bool | m_finalised |
TDirectory * | m_slicedir = 0 |
bool | m_uniform |
Static Private Attributes | |
static bool | s_mAddDirectoryStatus |
static bool | s_interpolate_flag |
static const std::string | s_rversion = "resplot-v29" |
static bool | s_oldrms95 = true |
temporarily allow toggeling between old and new rms95 error estimates More... | |
static bool | s_scalerms95 = true |
static bool | s_nofit = false |
static ERROR | s_ErrorSet = Resplot::OK |
|
private |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
virtual |
Definition at line 174 of file Resplot.cxx.
|
inlinestatic |
|
inlineprivate |
|
inlineprivate |
|
inlineprivate |
|
inline |
|
inlineprivate |
|
static |
|
static |
after value x, combine each N bins into a single bin
combine bins in a 2D histogram it takes a value, x and all the bins with BinLowEdge > x get combined N bins at a time.
Definition at line 667 of file Resplot.cxx.
|
static |
combine bins along the x axis combine bins such that the stat precision is better than epsilon
combine bins in a 2D histogram it takes a value, x and all the bins with BinLowEdge > x get combined N bins at a time.
bin contentes
bin error
Definition at line 715 of file Resplot.cxx.
|
static |
combine bins along the x axis after value x, combine each N bins into a single bin
combine bins in a 2D histogram it takes a value, x and all the bins with BinLowEdge > x get combined N bins at a time.
Definition at line 606 of file Resplot.cxx.
|
inlineprivate |
|
inlineprivate |
|
inlineprivate |
|
inlineprivate |
Int_t Resplot::DWrite | ( | TDirectory * | g = 0 | ) | const |
boooo, need to use the stupid Int_t class because I foolishly gave this function the same name as TObject::Write
Definition at line 342 of file Resplot.cxx.
|
inline |
int Resplot::Finalise | ( | double | a = -999 , |
double | b = -999 , |
||
TF1 *(*)(TH1D *s, double a, double b) | func = Resplot::FitGaussian |
||
) |
Definition at line 388 of file Resplot.cxx.
|
inline |
|
static |
|
inline |
|
static |
Definition at line 1220 of file Resplot.cxx.
|
static |
Definition at line 1159 of file Resplot.cxx.
|
static |
if the fit is "bad" fit only to the central region
calculate difference from maximum of fit, and hist maximum
Definition at line 1080 of file Resplot.cxx.
|
static |
Definition at line 1025 of file Resplot.cxx.
|
static |
Definition at line 1051 of file Resplot.cxx.
|
static |
Definition at line 2082 of file Resplot.cxx.
|
inline |
|
static |
Definition at line 1288 of file Resplot.cxx.
|
static |
use approximate root errors for speed
Definition at line 1673 of file Resplot.cxx.
|
static |
NB: try to find with respect to maximum bin, rather than the mean. double m = s->GetMean();
double m = FindMean(s); int imax = s->GetXaxis()->FindBin(m);
root does not calculate the uncertainty on the rms correctly
Definition at line 1754 of file Resplot.cxx.
|
static |
calculate the
a "corrected" rms of the inner 0.95% of the data, corrected such that for a gaussian, will return 1.
Definition at line 1687 of file Resplot.cxx.
|
static |
this line causes a crash, even though s->GetXaxis() returns the x axis ok
root does not calculate the uncertainty on the rms correctly
a "corrected" rms of the inner 0.95% of the data, corrected such that for a gaussian, will return 1.
Definition at line 1408 of file Resplot.cxx.
|
static |
Definition at line 1926 of file Resplot.cxx.
|
static |
Definition at line 1036 of file Resplot.cxx.
|
static |
Definition at line 1031 of file Resplot.cxx.
|
static |
Definition at line 1966 of file Resplot.cxx.
|
inlineprivate |
|
inlineprivate |
|
static |
TH1D * Resplot::GetEfficiencies | ( | const std::string & | hname, |
double | lower, | ||
double | upper | ||
) |
Definition at line 958 of file Resplot.cxx.
TH1D * Resplot::GetEfficiencies | ( | const std::string & | hname, |
double | Nsigma | ||
) |
Definition at line 989 of file Resplot.cxx.
StatVal Resplot::GetEfficiency | ( | TH1D * | h, |
double | lower, | ||
double | upper | ||
) |
Definition at line 932 of file Resplot.cxx.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
void Resplot::Initialise | ( | const std::string & | name, |
const std::vector< double > & | a, | ||
const std::vector< double > & | b | ||
) |
Definition at line 243 of file Resplot.cxx.
void Resplot::Initialise | ( | const std::string & | name, |
const std::vector< double > & | a, | ||
int | n2, | ||
double | a2, | ||
double | b2 | ||
) |
Definition at line 236 of file Resplot.cxx.
void Resplot::Initialise | ( | const std::string & | name, |
int | n1, | ||
const double * | a1, | ||
int | n2, | ||
const double * | a2 | ||
) |
Definition at line 296 of file Resplot.cxx.
void Resplot::Initialise | ( | const std::string & | name, |
int | n1, | ||
const double * | a1, | ||
int | n2, | ||
double | a2, | ||
double | b2 | ||
) |
Definition at line 251 of file Resplot.cxx.
void Resplot::Initialise | ( | const std::string & | name, |
int | n1, | ||
double | a1, | ||
double | b1, | ||
int | n2, | ||
double | a2, | ||
double | b2 | ||
) |
Definition at line 194 of file Resplot.cxx.
|
inline |
integrate all the slices and refit the mean etc. not yet ...
|
inline |
|
inline |
|
inline |
|
inline |
Definition at line 497 of file Resplot.h.
operators
Definition at line 466 of file Resplot.h.
Definition at line 891 of file Resplot.cxx.
|
inline |
|
static |
|
inline |
|
inlinestatic |
|
inlinestatic |
|
inlineprivate |
|
inlineprivate |
|
inlineprivate |
|
inline |
|
inline |
|
inline |
|
inlineprivate |
|
inlineprivate |
|
inline |
|
inlinestatic |
|
inline |
|
inline |
|
staticprivate |
|
staticprivate |
|
staticprivate |