ITK
4.2.0
Insight Segmentation and Registration Toolkit
|
#include <itkGaussianDistribution.h>
Public Types | |
typedef SmartPointer< const Self > | ConstPointer |
typedef SmartPointer< Self > | Pointer |
typedef GaussianDistribution | Self |
typedef ProbabilityDistribution | Superclass |
Public Types inherited from itk::Statistics::ProbabilityDistribution | |
typedef Array< double > | ParametersType |
Public Types inherited from itk::Object | |
Public Types inherited from itk::LightObject |
Public Member Functions | |
virtual ::itk::LightObject::Pointer | CreateAnother (void) const |
virtual double | EvaluateCDF (double x) const |
virtual double | EvaluateCDF (double x, const ParametersType &) const |
virtual double | EvaluateCDF (double x, double mean, double variance) const |
virtual double | EvaluateInverseCDF (double p) const |
virtual double | EvaluateInverseCDF (double p, const ParametersType &) const |
virtual double | EvaluateInverseCDF (double p, double mean, double variance) const |
virtual double | EvaluatePDF (double x) const |
virtual double | EvaluatePDF (double x, const ParametersType &) const |
virtual double | EvaluatePDF (double x, double mean, double variance) const |
virtual double | GetMean () const |
virtual const char * | GetNameOfClass () const |
virtual SizeValueType | GetNumberOfParameters () const |
virtual double | GetVariance () const |
virtual bool | HasMean () const |
virtual bool | HasVariance () const |
virtual void | SetMean (double) |
virtual void | SetVariance (double) |
Public Member Functions inherited from itk::Statistics::ProbabilityDistribution | |
virtual const ParametersType & | GetParameters () |
virtual void | SetParameters (const ParametersType ¶ms) |
Public Member Functions inherited from itk::Object | |
unsigned long | AddObserver (const EventObject &event, Command *) |
unsigned long | AddObserver (const EventObject &event, Command *) const |
virtual void | DebugOff () const |
virtual void | DebugOn () const |
Command * | GetCommand (unsigned long tag) |
bool | GetDebug () const |
MetaDataDictionary & | GetMetaDataDictionary (void) |
const MetaDataDictionary & | GetMetaDataDictionary (void) const |
virtual unsigned long | GetMTime () const |
virtual const TimeStamp & | GetTimeStamp () const |
bool | HasObserver (const EventObject &event) const |
void | InvokeEvent (const EventObject &) |
void | InvokeEvent (const EventObject &) const |
virtual void | Modified () const |
virtual void | Register () const |
void | RemoveAllObservers () |
void | RemoveObserver (unsigned long tag) |
void | SetDebug (bool debugFlag) const |
void | SetMetaDataDictionary (const MetaDataDictionary &rhs) |
virtual void | SetReferenceCount (int) |
virtual void | UnRegister () const |
Public Member Functions inherited from itk::LightObject | |
virtual void | Delete () |
virtual int | GetReferenceCount () const |
itkCloneMacro (Self) | |
void | Print (std::ostream &os, Indent indent=0) const |
Static Public Member Functions | |
static double | CDF (double x) |
static double | CDF (double x, const ParametersType &) |
static double | CDF (double x, double mean, double variance) |
static double | InverseCDF (double p, const ParametersType &) |
static double | InverseCDF (double p, double mean, double variance) |
static Pointer | New () |
static double | PDF (double x) |
static double | PDF (double x, const ParametersType &) |
static double | PDF (double x, double mean, double variance) |
static double | InverseCDF (double p) |
Protected Member Functions | |
GaussianDistribution (void) | |
void | PrintSelf (std::ostream &os, Indent indent) const |
virtual | ~GaussianDistribution (void) |
Protected Member Functions inherited from itk::Statistics::ProbabilityDistribution | |
ProbabilityDistribution (void) | |
virtual | ~ProbabilityDistribution (void) |
Protected Member Functions inherited from itk::Object | |
Object () | |
bool | PrintObservers (std::ostream &os, Indent indent) const |
virtual void | SetTimeStamp (const TimeStamp &time) |
virtual | ~Object () |
Protected Member Functions inherited from itk::LightObject | |
virtual LightObject::Pointer | InternalClone () const |
LightObject () | |
virtual void | PrintHeader (std::ostream &os, Indent indent) const |
virtual void | PrintTrailer (std::ostream &os, Indent indent) const |
virtual | ~LightObject () |
Private Member Functions | |
GaussianDistribution (const Self &) | |
void | operator= (const Self &) |
Additional Inherited Members | |
Protected Attributes inherited from itk::Statistics::ProbabilityDistribution | |
ParametersType | m_Parameters |
GaussianDistribution class defines the interface for a univariate Gaussian distribution (pdfs, cdfs, etc.).
GaussianDistribution provides access to the probability density function (pdf), the cumulative distribution function (cdf), and the inverse cumulative distribution function for a Gaussian distribution.
The EvaluatePDF(), EvaluateCDF, EvaluateInverseCDF() methods are all virtual, allowing algorithms to be written with an abstract interface to a distribution (with said distribution provided to the algorithm at run-time). Static methods, not requiring an instance of the distribution, are also provided. The static methods allow for optimized access to distributions when the distribution is known a priori to the algorithm.
GaussianDistributions are univariate. Multivariate versions may be provided under a separate superclass (since the parameters to the pdf and cdf would have to be vectors not scalars).
GaussianDistributions can be used for Z-score statistical tests.
Definition at line 60 of file itkGaussianDistribution.h.
typedef SmartPointer< const Self > itk::Statistics::GaussianDistribution::ConstPointer |
Reimplemented from itk::Statistics::ProbabilityDistribution.
Definition at line 68 of file itkGaussianDistribution.h.
Reimplemented from itk::Statistics::ProbabilityDistribution.
Definition at line 67 of file itkGaussianDistribution.h.
Standard class typedefs
Reimplemented from itk::Statistics::ProbabilityDistribution.
Definition at line 65 of file itkGaussianDistribution.h.
Reimplemented from itk::Statistics::ProbabilityDistribution.
Definition at line 66 of file itkGaussianDistribution.h.
|
protected |
|
inlineprotectedvirtual |
Definition at line 235 of file itkGaussianDistribution.h.
|
private |
|
static |
Static method to evaluate the cumulative distribution function (cdf) of a standardized (mean zero, unit variance) Gaussian. The static method provides optimized access without requiring an instance of the class. Accuracy is approximately 10^-8.
|
static |
Static method to evaluate the cumulative distribution function (cdf) of a Gaussian. The parameters of the distribution are passed as a parameter vector. The ordering of the parameters is (mean, variance). The static method provides optimized access without requiring an instance of the class.
|
static |
Static method to evaluate the cumulative distribution function (cdf) of a Gaussian. The parameters of the distribution are passed as separate values. The static method provides optimized access without requiring an instance of the class.
|
virtual |
Create an object from an instance, potentially deferring to a factory. This method allows you to create an instance of an object that is exactly the same type as the referring object. This is useful in cases where an object has been cast back to a base class.
Reimplemented from itk::Object.
|
virtual |
Evaluate the cumulative distribution function (cdf). The parameters of the distribution are assigned via SetParameters().
Implements itk::Statistics::ProbabilityDistribution.
|
virtual |
Evaluate the cumulative distribution function (cdf). The parameters for the distribution are passed as a parameters vector. The ordering of the parameters is (mean, variance).
Implements itk::Statistics::ProbabilityDistribution.
|
virtual |
Evaluate the cumulative distribution function (cdf). The parameters of the distribution are passed as separate parameters.
|
virtual |
Evaluate the inverse cumulative distribution function (inverse cdf). Parameter p must be between 0.0 and 1.0. The parameters of the distribution are assigned via SetParameters().
Implements itk::Statistics::ProbabilityDistribution.
|
virtual |
Evaluate the inverse cumulative distribution function (inverse cdf). Parameter p must be between 0.0 and 1.0. The parameters for the distribution are passed as a parameters vector. The ordering of the parameters is (mean, variance).
Implements itk::Statistics::ProbabilityDistribution.
|
virtual |
Evaluate the inverse cumulative distribution function (inverse cdf). Parameter p must be between 0.0 and 1.0. The parameters of the distribution are passed as separate parameters.
|
virtual |
Evaluate the probability density function (pdf). The parameters of the distribution are assigned via SetParameters().
Implements itk::Statistics::ProbabilityDistribution.
|
virtual |
Evaluate the probability density function (pdf). The parameters for the distribution are passed as a parameters vector. The ordering of the parameters is (mean, variance).
Implements itk::Statistics::ProbabilityDistribution.
|
virtual |
Evaluate the probability density function (pdf). The parameters of the distribution are passed as separate parameters.
|
virtual |
Get the mean of the Gaussian distribution. Defaults to 0.0. The mean is stored in position 0 of the parameters vector.
Implements itk::Statistics::ProbabilityDistribution.
|
virtual |
Strandard macros
Reimplemented from itk::Statistics::ProbabilityDistribution.
|
inlinevirtual |
Return the number of parameters. For a univariate Gaussian, this is 2 (mean, variance).
Implements itk::Statistics::ProbabilityDistribution.
Definition at line 78 of file itkGaussianDistribution.h.
|
virtual |
Get the variance of the Gaussian distribution. Defaults to 1.0. The variance is stored in position 1 of the parameters vector.
Implements itk::Statistics::ProbabilityDistribution.
|
inlinevirtual |
Does this distribution have a mean?
Implements itk::Statistics::ProbabilityDistribution.
Definition at line 133 of file itkGaussianDistribution.h.
|
inlinevirtual |
Does this distribution have a variance?
Implements itk::Statistics::ProbabilityDistribution.
Definition at line 145 of file itkGaussianDistribution.h.
|
static |
Static method to evaluate the inverse cumulative distribution function of a standardized (mean zero, unit variance) Gaussian. The static method provides optimized access without requiring an instance of the class. Parameter p must be between 0.0 and 1.0.
THis implementation was provided by Robert W. Cox from the Biophysics Research Institute at the Medical College of Wisconsin. This function is based off of a rational polynomial approximation to the inverse Gaussian CDF which can be found in M. Abramowitz and I.A. Stegun. Handbook of Mathematical Functions with Formulas, Graphs, and Mathematical Tables. John Wiley & Sons. New York. Equation 26.2.23. pg. 933. 1972.
Since the initial approximation only provides an estimate within 4.5 E-4 of the true value, 3 Newton-Raphson interations are used to refine the approximation. Accuracy is approximately 10^-8.
Let, Q(x) = (1/sqrt(2*pi)) Int_{x}^{infinity} e^{-t^2/2} dt = 0.5 * erfc(x/sqrt(2))
Given p, this function computes x such that Q(x) = p, for 0 < p < 1
Note that the Gaussian CDF is defined as P(x) = (1/sqrt(2*pi)) Int_{-infinity}{x} e^{-t^2/2} dt = 1 - Q(x)
This function has been modified to compute the inverse of P(x) instead of Q(x).
|
static |
Static method to evaluate the inverse cumulative distribution function of a Gaussian. The parameters of the distribution are passed as a parameter vector. The ordering of the parameters is (mean, variance). The static method provides optimized access without requiring an instance of the class. Parameter p must be between 0.0 and 1.0
|
static |
Static method to evaluate the inverse cumulative distribution function of a Gaussian. The parameters of the distribution are passed as separate values. The static method provides optimized access without requiring an instance of the class. Parameter p must be between 0.0 and 1.0
|
static |
Method for creation through the object factory.
Reimplemented from itk::Object.
|
private |
Mutex lock to protect modification to the reference count
Reimplemented from itk::Statistics::ProbabilityDistribution.
|
static |
Static method to evaluate the probability density function (pdf) of a standardized (mean zero, unit variance) Gaussian. The static method provides optimized access without requiring an instance of the class.
|
static |
Static method to evaluate the probability density function (pdf) of a Gaussian. The parameters of the distribution are passed as a parameter vector. The ordering of the parameters is (mean, variance). The static method provides optimized access without requiring an instance of the class.
|
static |
Static method to evaluate the probability density function (pdf) of a Gaussian. The parameters of the distribution are passed as separate values. The static method provides optimized access without requiring an instance of the class.
|
protectedvirtual |
Methods invoked by Print() to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.
Reimplemented from itk::Statistics::ProbabilityDistribution.
|
virtual |
Set the mean of the Gaussian distribution. Defaults to 0.0. The mean is stored in position 0 of the parameters vector.
|
virtual |
Set the variance of the Gaussian distribution. Defaults to 1.0. The variance is stored in position 1 of the parameters vector.