npstat is hosted by Hepforge, IPPP Durham
NPStat  5.10.0
Inheritance diagram for npstat::AbsUnfold1D:
npstat::SmoothedEMUnfold1D npstat::MultiscaleEMUnfold1D

Public Member Functions

 AbsUnfold1D (const Matrix< double > &responseMatrix)
 
const Matrix< double > & responseMatrix () const
 
const Matrix< double > & transposedResponseMatrix () const
 
const std::vector< double > & efficiency () const
 
std::pair< double, double > smoothingNDoF () const
 
std::pair< double, double > responseNDoF () const
 
std::pair< double, double > smoothedResponseNDoF () const
 
std::pair< double, double > modelNDoF ()
 
virtual void setInitialApproximation (const double *approx, unsigned lenApprox)
 
virtual void clearInitialApproximation ()
 
virtual const std::vector< double > & getInitialApproximation () const
 
virtual void setFilter (const LocalPolyFilter1D *f)
 
virtual const LocalPolyFilter1DgetFilter (bool throwIfNull=false) const
 
virtual void useConvolutions (const bool b)
 
bool usingConvolutions () const
 
virtual bool unfold (const double *observed, unsigned lenObserved, const Matrix< double > *observationCovarianceMatrix, double *unfolded, unsigned lenUnfolded, Matrix< double > *unfoldedCovarianceMatrix)=0
 

Static Public Member Functions

static double probDelta (const double *prev, const double *next, const unsigned len)
 
static Matrix< double > observationCovariance (const double *yhat, unsigned lenObserved, bool isMultinomial)
 

Protected Member Functions

void buildUniformInitialApproximation (const double *observed, unsigned lenObserved, std::vector< double > *result) const
 
void validateDimensions (unsigned lenObserved, unsigned lenUnfold) const
 

Static Protected Member Functions

static void validateDensity (const double *observ, unsigned lenObserved)
 

Constructor & Destructor Documentation

◆ AbsUnfold1D()

npstat::AbsUnfold1D::AbsUnfold1D ( const Matrix< double > &  responseMatrix)
explicit

Number of rows of the response matrix should be equal to the number of discretization intervals in the space of observations. Number of columns should be equal to the number of intervals in the original (unfolded) space.

Member Function Documentation

◆ clearInitialApproximation()

virtual void npstat::AbsUnfold1D::clearInitialApproximation ( )
virtual

Clear the initial approximation to the unfolded solution

◆ getFilter()

virtual const LocalPolyFilter1D* npstat::AbsUnfold1D::getFilter ( bool  throwIfNull = false) const
virtual

Retrieve the smoothing filter used

◆ getInitialApproximation()

virtual const std::vector<double>& npstat::AbsUnfold1D::getInitialApproximation ( ) const
virtual

Return the initial approximation to the unfolded solution

◆ modelNDoF()

std::pair<double, double> npstat::AbsUnfold1D::modelNDoF ( )

Effective number of degrees of freedom for the smearing model (for use in AIC, etc). Will call "unfold" internally, so can't be a const method.

◆ observationCovariance()

static Matrix<double> npstat::AbsUnfold1D::observationCovariance ( const double *  yhat,
unsigned  lenObserved,
bool  isMultinomial 
)
static

Procedure for building covariance matrix of observations according to either Poisson or multinomial distribution

◆ probDelta()

static double npstat::AbsUnfold1D::probDelta ( const double *  prev,
const double *  next,
const unsigned  len 
)
static

An L1-like relative distance between two unnormalized density-like arrays. Can be used as a convergence measure.

◆ setFilter()

virtual void npstat::AbsUnfold1D::setFilter ( const LocalPolyFilter1D f)
virtual

Set the smoothing filter used. The filter will not be copied. It is the responsibility of the user of this class to ensure that the lifetime of the filter exceeds the lifetime of this object.

◆ setInitialApproximation()

virtual void npstat::AbsUnfold1D::setInitialApproximation ( const double *  approx,
unsigned  lenApprox 
)
virtual

Set the initial approximation to the unfolded solution

◆ smoothingNDoF()

std::pair<double, double> npstat::AbsUnfold1D::smoothingNDoF ( ) const

The first element of the pair is the entropic nDoF and the second is the nDoF based on the trace

◆ unfold()

virtual bool npstat::AbsUnfold1D::unfold ( const double *  observed,
unsigned  lenObserved,
const Matrix< double > *  observationCovarianceMatrix,
double *  unfolded,
unsigned  lenUnfolded,
Matrix< double > *  unfoldedCovarianceMatrix 
)
pure virtual

Method to be implemented by derived classes. "lenObserved" and "lenUnfolded" should be consistent with the dimensionality of the response matrix provided in the constructor. The "observationCovarianceMatrix" pointer to the covariance matrix of observations can be NULL in which case this covariance matrix will be evaluated internally (typically, assuming either Poisson or multinomial distributions for the observed counts). "unfoldedCovarianceMatrix" pointer, if not NULL, should be used to return the covariance matrix of unfolded values with dimensions (lenUnfolded x lenUnfolded). This function should return "true" on success and "false" on failure.

Implemented in npstat::SmoothedEMUnfold1D.

◆ useConvolutions()

virtual void npstat::AbsUnfold1D::useConvolutions ( const bool  b)
inlinevirtual

Switch between using filtering or convolution

◆ usingConvolutions()

bool npstat::AbsUnfold1D::usingConvolutions ( ) const
inline

Check if the filter should use "filter" or "convolve" method


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