STK++ 0.9.13
STK::MLMixtureCriterion Class Reference

Derived class of Criterion for computing the Maximum Likelihood Criterion This criterion does not penalize the model and return minux two times the log likelihood of the model. More...

#include <STK_MixtureCriterion.h>

Inheritance diagram for STK::MLMixtureCriterion:
Inheritance graph

Public Member Functions

 MLMixtureCriterion ()
 Default Constructor.
 
 MLMixtureCriterion (IMixtureStatModel *const p_composer)
 Constructor.
 
 MLMixtureCriterion (MLMixtureCriterion const &criterion)
 copy Constructor.
 
virtual ~MLMixtureCriterion ()
 virtual destructor.
 
MLMixtureCriterionclone () const
 clone pattern
 
virtual bool run ()
 implementation of the virtual method run
 
- Public Member Functions inherited from STK::IMixtureCriterion
virtual ~IMixtureCriterion ()
 Destructor.
 
Real constvalue () const
 
void setModel (IMixtureStatModel const *p_composer)
 
- Public Member Functions inherited from STK::IRunnerBase
String consterror () const
 get the last error message.
 

Additional Inherited Members

- Protected Member Functions inherited from STK::IMixtureCriterion
 IMixtureCriterion ()
 Default Constructor.
 
 IMixtureCriterion (IMixtureStatModel const *p_composer)
 Constructor.
 
 IMixtureCriterion (IMixtureCriterion const &criterion)
 copy Constructor.
 
- Protected Member Functions inherited from STK::IRunnerBase
 IRunnerBase ()
 default constructor
 
 IRunnerBase (IRunnerBase const &runner)
 copy constructor
 
virtual ~IRunnerBase ()
 destructor
 
virtual void update ()
 update the runner.
 
- Protected Attributes inherited from STK::IMixtureCriterion
IMixtureStatModel constp_composer_
 The current statistical model to use.
 
Real value_
 Computed value of the criterion.
 
- Protected Attributes inherited from STK::IRunnerBase
String msg_error_
 String with the last error message.
 
bool hasRun_
 true if run has been used, false otherwise
 

Detailed Description

Derived class of Criterion for computing the Maximum Likelihood Criterion This criterion does not penalize the model and return minux two times the log likelihood of the model.

\[
  -2 \ln{L}
\]

Definition at line 154 of file STK_MixtureCriterion.h.

Constructor & Destructor Documentation

◆ MLMixtureCriterion() [1/3]

STK::MLMixtureCriterion::MLMixtureCriterion ( )
inline

Default Constructor.

Definition at line 158 of file STK_MixtureCriterion.h.

IMixtureCriterion()
Default Constructor.

Referenced by clone().

◆ MLMixtureCriterion() [2/3]

STK::MLMixtureCriterion::MLMixtureCriterion ( IMixtureStatModel *const  p_composer)
inline

Constructor.

Parameters
p_composerapointer on the current model

Definition at line 162 of file STK_MixtureCriterion.h.

163 : IMixtureCriterion(p_composer) {}

◆ MLMixtureCriterion() [3/3]

STK::MLMixtureCriterion::MLMixtureCriterion ( MLMixtureCriterion const criterion)
inline

copy Constructor.

Parameters
criterionthe criterion to copy

Definition at line 167 of file STK_MixtureCriterion.h.

168 : IMixtureCriterion(criterion) {}

◆ ~MLMixtureCriterion()

virtual STK::MLMixtureCriterion::~MLMixtureCriterion ( )
inlinevirtual

virtual destructor.

Definition at line 170 of file STK_MixtureCriterion.h.

170{}

Member Function Documentation

◆ clone()

MLMixtureCriterion * STK::MLMixtureCriterion::clone ( ) const
inline

clone pattern

Definition at line 172 of file STK_MixtureCriterion.h.

172{ return new MLMixtureCriterion(*this);}
MLMixtureCriterion()
Default Constructor.

References MLMixtureCriterion().

◆ run()

bool STK::MLMixtureCriterion::run ( )
virtual

implementation of the virtual method run

Implements STK::IRunnerBase.

Definition at line 74 of file STK_MixtureCriterion.cpp.

75{
76 if (!p_composer_)
78 return false;
79 }
81 return true;
82}
#define STKERROR_NO_ARG(Where, Error)
Definition STK_Macros.h:49
Real value_
Computed value of the criterion.
IMixtureStatModel const * p_composer_
The current statistical model to use.
String msg_error_
String with the last error message.
Definition STK_IRunner.h:96
virtual bool run()
implementation of the virtual method run

References STK::IStatModelBase::lnLikelihood(), STK::IRunnerBase::msg_error_, STK::IMixtureCriterion::p_composer_, run(), STKERROR_NO_ARG, and STK::IMixtureCriterion::value_.

Referenced by run().


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