hpstr
The Heavy Photon Search Toolkit for Reconstruction (hpstr) provides an interface to physics data from the HPS experiment saved in the LCIO format and converts it into an ROOT based format.
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Public Member Functions | Private Attributes | List of all members
HpsFitResult Class Reference

description More...

#include <HpsFitResult.h>

Public Member Functions

 HpsFitResult ()
 
 ~HpsFitResult ()
 
TFitResultPtr getBkgFitResult ()
 Get background fit result.
 
TFitResultPtr getBkgToysFitResult ()
 Get background toy model fit result.
 
TFitResultPtr getCompFitResult ()
 Get the complete fit result.
 
void addLikelihood (double likelihood)
 description
 
void addSignalYield (double signal_yield)
 description
 
double getCorrectedMass () const
 Get the corrected mass.
 
double getIntegral ()
 Get the integral within the fit window.
 
double getMass () const
 Get the mass hypothesis for the fit.
 
double getQ0 ()
 description
 
double getPValue ()
 description
 
double getFullBkgRate ()
 Get the background rate obtained from the signal+background hit at the mass hypo.
 
double getFullBkgRateError ()
 Get the background rate error from the signal+background fit at the mass hypo.
 
float getSignalYield ()
 Get the signal yield obtained from the signal+background fit.
 
float getSignalYieldErr ()
 Get the error of the signal yield.
 
double getUpperLimit ()
 Get the upper fit limit.
 
double getUpperLimitPValue ()
 Get the p-value at the upper limit.
 
double getWindowSize ()
 Get the size of the fit window.
 
std::vector< double > getLikelihoods ()
 Get the likelihoods.
 
std::vector< double > getSignalYields ()
 Get the signal yields.
 
void setIntegral (double integral)
 Set the integral.
 
void setQ0 (double q0)
 Set Q0.
 
void setPValue (double p_value)
 Set the p-value.
 
void setBkgFitResult (TFitResultPtr bkg_result)
 Set the result from the background only fit.
 
void setBkgToysFitResult (TFitResultPtr bkg_toy_result)
 Set the result from the background only fit for generating toys.
 
void setCompFitResult (TFitResultPtr comp_result)
 Set the result from the signal+background only fit.
 
void setMass (double mass)
 Set mass hypothesis used for this fit.
 
void setCorrectedMass (double cmass)
 Set the corrected mass.
 
void setPolyOrder (int poly_order)
 Set the order polynomial used by the fitter.
 
void setBkgModelType (FitFunction::BkgModel bkg_model)
 Sets the type of background fit function used by the fitter.
 
void setUpperLimit (double upper_limit)
 Set the 2 sigma upper limit.
 
void setUpperLimitPValue (double upper_limit_p_value)
 Set the p-value at the end of the upper limit calculation.
 
void setWindowSize (double window_size)
 Set the size of the fit window used to get this results.
 
void setBinWidth (double bin_width)
 Set the size of the fit window used to get this results.
 

Private Attributes

TFitResultPtr bkg_result_ {nullptr}
 
TFitResultPtr bkg_toy_result_ {nullptr}
 
TFitResultPtr comp_result_ {nullptr}
 
std::vector< double > _likelihoods
 
std::vector< double > _signal_yields
 
double _integral {0}
 
double mass_hypo_
 
double _cmass {0}
 
double q0_
 
double p_value_
 
double poly_order_ {0}
 
FitFunction::BkgModel bkg_model_ {FitFunction::BkgModel::EXP_CHEBYSHEV}
 
double upper_limit_
 
double _upper_limit_p_value {-9999}
 
double window_size_
 
double bin_width_
 

Detailed Description

description

details

Definition at line 15 of file HpsFitResult.h.

Constructor & Destructor Documentation

◆ HpsFitResult()

Default constructor

Definition at line 3 of file HpsFitResult.cxx.

◆ ~HpsFitResult()

Definition at line 10 of file HpsFitResult.cxx.

Member Function Documentation

◆ addLikelihood()

void addLikelihood ( double  likelihood)
inline

description

Parameters
likelihood

Definition at line 50 of file HpsFitResult.h.

◆ addSignalYield()

void addSignalYield ( double  signal_yield)
inline

description

Parameters
signal_yield

Definition at line 57 of file HpsFitResult.h.

◆ getBkgFitResult()

TFitResultPtr getBkgFitResult ( )
inline

Get background fit result.

Returns
TFitResultPtr

Definition at line 29 of file HpsFitResult.h.

◆ getBkgToysFitResult()

TFitResultPtr getBkgToysFitResult ( )
inline

Get background toy model fit result.

Returns
TFitResultPtr

Definition at line 36 of file HpsFitResult.h.

◆ getCompFitResult()

TFitResultPtr getCompFitResult ( )
inline

Get the complete fit result.

Returns
TFitResultPtr

Definition at line 43 of file HpsFitResult.h.

◆ getCorrectedMass()

double getCorrectedMass ( ) const
inline

Get the corrected mass.

Returns
double

Definition at line 64 of file HpsFitResult.h.

◆ getFullBkgRate()

double getFullBkgRate ( )

Get the background rate obtained from the signal+background hit at the mass hypo.

Returns
double The bkg rate obtained from the sig+bkg fit at the mass hypo.

Definition at line 12 of file HpsFitResult.cxx.

◆ getFullBkgRateError()

double getFullBkgRateError ( )

Get the background rate error from the signal+background fit at the mass hypo.

Returns
double The bkg rate error from the sig+bkg fit at the mass hypo.

Definition at line 49 of file HpsFitResult.cxx.

◆ getIntegral()

double getIntegral ( )
inline

Get the integral within the fit window.

Returns
double _integral The integral within the fit window.

Definition at line 71 of file HpsFitResult.h.

◆ getLikelihoods()

std::vector< double > getLikelihoods ( )
inline

Get the likelihoods.

Returns
std::vector<double>

Definition at line 148 of file HpsFitResult.h.

◆ getMass()

double getMass ( ) const
inline

Get the mass hypothesis for the fit.

Returns
double mass_hypo_ The mass hypothesis used for this fit.

Definition at line 78 of file HpsFitResult.h.

◆ getPValue()

double getPValue ( )
inline

description

Returns
double p_value_ description

Definition at line 92 of file HpsFitResult.h.

◆ getQ0()

double getQ0 ( )
inline

description

Returns
double q0_ description

Definition at line 85 of file HpsFitResult.h.

◆ getSignalYield()

float getSignalYield ( )
inline

Get the signal yield obtained from the signal+background fit.

Returns
float The signal yield obtained from the sig+bkg fit.

Definition at line 113 of file HpsFitResult.h.

◆ getSignalYieldErr()

float getSignalYieldErr ( )
inline

Get the error of the signal yield.

Returns
float The error on the signal yield.

Definition at line 120 of file HpsFitResult.h.

◆ getSignalYields()

std::vector< double > getSignalYields ( )
inline

Get the signal yields.

Returns
std::vector<double>

Definition at line 155 of file HpsFitResult.h.

◆ getUpperLimit()

double getUpperLimit ( )
inline

Get the upper fit limit.

Returns
double the upper limit

Definition at line 127 of file HpsFitResult.h.

◆ getUpperLimitPValue()

double getUpperLimitPValue ( )
inline

Get the p-value at the upper limit.

Returns
double the p-value

Definition at line 134 of file HpsFitResult.h.

◆ getWindowSize()

double getWindowSize ( )
inline

Get the size of the fit window.

Returns
double The size of the fit window used.

Definition at line 141 of file HpsFitResult.h.

◆ setBinWidth()

void setBinWidth ( double  bin_width)
inline

Set the size of the fit window used to get this results.

Parameters
bin_widthThe size of the fit window.

Definition at line 257 of file HpsFitResult.h.

◆ setBkgFitResult()

void setBkgFitResult ( TFitResultPtr  bkg_result)
inline

Set the result from the background only fit.

Parameters
bkg_resultResult from the background only fit.

Definition at line 187 of file HpsFitResult.h.

◆ setBkgModelType()

void setBkgModelType ( FitFunction::BkgModel  bkg_model)
inline

Sets the type of background fit function used by the fitter.

Parameters
bkg_modelThe background fit model.

Definition at line 229 of file HpsFitResult.h.

◆ setBkgToysFitResult()

void setBkgToysFitResult ( TFitResultPtr  bkg_toy_result)
inline

Set the result from the background only fit for generating toys.

Parameters
bkg_toy_resultResult from the background only fit with toy model.

Definition at line 194 of file HpsFitResult.h.

◆ setCompFitResult()

void setCompFitResult ( TFitResultPtr  comp_result)
inline

Set the result from the signal+background only fit.

Parameters
comp_resultResult from the signal+background only fit.

Definition at line 201 of file HpsFitResult.h.

◆ setCorrectedMass()

void setCorrectedMass ( double  cmass)
inline

Set the corrected mass.

Parameters
cmasscorrected mass

Definition at line 215 of file HpsFitResult.h.

◆ setIntegral()

void setIntegral ( double  integral)
inline

Set the integral.

Parameters
integral

Definition at line 166 of file HpsFitResult.h.

◆ setMass()

void setMass ( double  mass)
inline

Set mass hypothesis used for this fit.

Parameters
massThe mass hypothesis.

Definition at line 208 of file HpsFitResult.h.

◆ setPolyOrder()

void setPolyOrder ( int  poly_order)
inline

Set the order polynomial used by the fitter.

Parameters
poly_orderPolynomial order used by the fitter.

Definition at line 222 of file HpsFitResult.h.

◆ setPValue()

void setPValue ( double  p_value)
inline

Set the p-value.

Parameters
p_value

Definition at line 180 of file HpsFitResult.h.

◆ setQ0()

void setQ0 ( double  q0)
inline

Set Q0.

Parameters
q0

Definition at line 173 of file HpsFitResult.h.

◆ setUpperLimit()

void setUpperLimit ( double  upper_limit)
inline

Set the 2 sigma upper limit.

Parameters
upper_limitThe 2 sigma upper limit.

Definition at line 236 of file HpsFitResult.h.

◆ setUpperLimitPValue()

void setUpperLimitPValue ( double  upper_limit_p_value)
inline

Set the p-value at the end of the upper limit calculation.

Parameters
upper_limit_p_valueThe p-value at the end of the upper limit calculation

Definition at line 243 of file HpsFitResult.h.

◆ setWindowSize()

void setWindowSize ( double  window_size)
inline

Set the size of the fit window used to get this results.

Parameters
window_sizeThe size of the fit window.

Definition at line 250 of file HpsFitResult.h.

Member Data Documentation

◆ _cmass

double _cmass {0}
private

corrected mass

Definition at line 282 of file HpsFitResult.h.

◆ _integral

double _integral {0}
private

Total number of events within the fit window.

Definition at line 276 of file HpsFitResult.h.

◆ _likelihoods

std::vector<double> _likelihoods
private

description

Definition at line 270 of file HpsFitResult.h.

◆ _signal_yields

std::vector<double> _signal_yields
private

description

Definition at line 273 of file HpsFitResult.h.

◆ _upper_limit_p_value

double _upper_limit_p_value {-9999}
private

p-value at the upper limit.

Definition at line 300 of file HpsFitResult.h.

◆ bin_width_

double bin_width_
private

Definition at line 306 of file HpsFitResult.h.

◆ bkg_model_

Type of background fit function to use.

Definition at line 294 of file HpsFitResult.h.

◆ bkg_result_

TFitResultPtr bkg_result_ {nullptr}
private

Result from fit using a background model only.

Definition at line 261 of file HpsFitResult.h.

◆ bkg_toy_result_

TFitResultPtr bkg_toy_result_ {nullptr}
private

Result from fit using a background model for generating toys.

Definition at line 264 of file HpsFitResult.h.

◆ comp_result_

TFitResultPtr comp_result_ {nullptr}
private

Result from fit using a signal+background model.

Definition at line 267 of file HpsFitResult.h.

◆ mass_hypo_

double mass_hypo_
private

Mass hypothesis.

Definition at line 279 of file HpsFitResult.h.

◆ p_value_

double p_value_
private

p-value.

Definition at line 288 of file HpsFitResult.h.

◆ poly_order_

double poly_order_ {0}
private

Order polynomial used by the fitter.

Definition at line 291 of file HpsFitResult.h.

◆ q0_

double q0_
private

q0 value

Definition at line 285 of file HpsFitResult.h.

◆ upper_limit_

double upper_limit_
private

2 sigma upper limit on the signal.

Definition at line 297 of file HpsFitResult.h.

◆ window_size_

double window_size_
private

Definition at line 303 of file HpsFitResult.h.


The documentation for this class was generated from the following files: