STK++ 0.9.13
|
A joint Bernoulli model is a statistical model of the form: following form. More...
#include <STK_ModelBernoulli_pj.h>
Public Types | |
typedef DataBridge< Data_ > | Data |
Type of the container storing the data. | |
typedef hidden::Traits< Data_ >::Row | RowVector |
typedef WColVector_ | WColVector |
Type of the array storing the weights of the data. | |
typedef hidden::Traits< Data_ >::Type | Type |
Type of the data in the container. | |
typedef IMultiStatModel< ModelBernoulli_pj< Data_, WColVector_ > > | Base |
Base class. | |
![]() | |
typedef hidden::StatModelTraits< ModelBernoulli_pj< Data_, WColVector_ > >::Data | Data |
Type of the container with the data. | |
typedef hidden::StatModelTraits< ModelBernoulli_pj< Data_, WColVector_ > >::Type | Type |
Type of the data in the container. | |
typedef hidden::StatModelTraits< ModelBernoulli_pj< Data_, WColVector_ > >::WColVector | WColVector |
Type of the vector with the weights. | |
typedef hidden::StatModelTraits< ModelBernoulli_pj< Data_, WColVector_ > >::Parameters | Parameters |
Type of the parameters of the Model. | |
Public Member Functions | |
ModelBernoulli_pj () | |
default constructor. | |
ModelBernoulli_pj (Data const &data) | |
Constructor with data set. | |
ModelBernoulli_pj (Data const *p_data) | |
Constructor with a ptr on the data set. | |
ModelBernoulli_pj (ModelBernoulli_pj const &model) | |
Copy constructor. | |
~ModelBernoulli_pj () | |
destructor | |
CPointX const & | prob () const |
CPointX const & | lnProb () const |
vector of the log probabilities of the observations | |
CPointX const & | ln1mProb () const |
vector of the log probabilities of the reversed observations | |
int | computeNbFreeParameters () const |
compute the number of free parameters | |
Real | computeLnLikelihood (RowVector const &rowData) const |
compute the log Likelihood of an observation. | |
void | computeParameters () |
compute the parameters | |
void | computeParameters (WColVector const &weights) |
compute the weighted parameters | |
void | writeParametersImpl (ostream &os) const |
Write the parameters on the output stream os. | |
![]() | |
Data const *const | p_data () const |
Parameters const & | param () const |
String const & | error () const |
void | setData (Data const *p_data) |
Set the data set. | |
bool | run () |
Estimate the parameters of the model and update the model. | |
bool | run (WColVector const &weights) |
compute the weighted empirical probability of success based on the observed variables. | |
void | writeParameters (ostream &os) |
void | writeParametersImpl (ostream &os) |
default implementation of the writeParameters method. | |
![]() | |
int | nbSample () const |
Real | lnNbSample () const |
int | nbVariable () const |
Real | lnLikelihood () const |
Real | likelihood () const |
int | nbFreeParameter () const |
Real | computeBIC () const |
Real | computeAIC () const |
Real | computeML () const |
![]() | |
Derived & | asDerived () |
static cast : return a reference of this with a cast to the derived class. | |
Derived const & | asDerived () const |
static cast : return a const reference of this with a cast to the derived class. | |
Derived * | asPtrDerived () |
static cast : return a ptr on a Derived of this with a cast to the derived class. | |
Derived const * | asPtrDerived () const |
static cast : return a ptr on a constant Derived of this with a cast to the derived class. | |
Derived * | clone () const |
create a leaf using the copy constructor of the Derived class. | |
Derived * | clone (bool isRef) const |
create a leaf using the copy constructor of the Derived class and a flag determining if the clone is a reference or not. | |
Additional Inherited Members | |
![]() | |
IMultiStatModel () | |
default constructor. | |
IMultiStatModel (Data const &data) | |
Constructor with data set. | |
IMultiStatModel (Data const *p_data) | |
Constructor with a ptr on the data set. | |
IMultiStatModel (IMultiStatModel const &model) | |
Copy constructor. | |
~IMultiStatModel () | |
destructor | |
Parameters & | param () |
Real | computeLnLikelihood () const |
compute the log Likelihood of the statistical model. | |
void | update () |
update the model if a new data set is set | |
![]() | |
IStatModelBase () | |
Default constructor. | |
IStatModelBase (int nbSample) | |
Constructor with specified dimension. | |
IStatModelBase (int nbSample, int nbVariable) | |
Constructor with specified dimension. | |
IStatModelBase (IStatModelBase const &model) | |
Copy constructor. | |
~IStatModelBase () | |
destructor | |
void | setNbFreeParameter (int const &nbFreeParameter) |
set the number of free parameters of the model | |
void | setNbSample (int const &nbSample) |
set the number of samples of the model | |
void | setNbVariable (int const &nbVariable) |
set the number of variables of the model | |
void | setLnLikelihood (Real const &lnLikelihood) |
set the log-likelihood of the model | |
void | initialize (int nbSample, int nbVariable) |
set the dimensions of the parameters of the model | |
![]() | |
IRecursiveTemplate () | |
constructor. | |
~IRecursiveTemplate () | |
destructor. | |
![]() | |
Data const * | p_data_ |
Pointer on the parameters of the model. | |
Parameters | param_ |
Pointer on the parameters of the model. | |
String | msg_error_ |
String with the last error message. | |
A joint Bernoulli model is a statistical model of the form: following form.
Definition at line 142 of file STK_ModelBernoulli_pj.h.
typedef IMultiStatModel< ModelBernoulli_pj<Data_, WColVector_> > STK::ModelBernoulli_pj< Data_, WColVector_ >::Base |
Base class.
Definition at line 153 of file STK_ModelBernoulli_pj.h.
typedef DataBridge<Data_> STK::ModelBernoulli_pj< Data_, WColVector_ >::Data |
Type of the container storing the data.
Definition at line 146 of file STK_ModelBernoulli_pj.h.
typedef hidden::Traits<Data_>::Row STK::ModelBernoulli_pj< Data_, WColVector_ >::RowVector |
Definition at line 147 of file STK_ModelBernoulli_pj.h.
typedef hidden::Traits<Data_>::Type STK::ModelBernoulli_pj< Data_, WColVector_ >::Type |
Type of the data in the container.
Definition at line 151 of file STK_ModelBernoulli_pj.h.
typedef WColVector_ STK::ModelBernoulli_pj< Data_, WColVector_ >::WColVector |
Type of the array storing the weights of the data.
Definition at line 149 of file STK_ModelBernoulli_pj.h.
|
inline |
default constructor.
Definition at line 158 of file STK_ModelBernoulli_pj.h.
|
inline |
Constructor with data set.
Definition at line 160 of file STK_ModelBernoulli_pj.h.
|
inline |
Constructor with a ptr on the data set.
Definition at line 162 of file STK_ModelBernoulli_pj.h.
|
inline |
|
inline |
Real STK::ModelBernoulli_pj< Data_, WColVector_ >::computeLnLikelihood | ( | RowVector const & | rowData | ) | const |
compute the log Likelihood of an observation.
Definition at line 191 of file STK_ModelBernoulli_pj.h.
References STK::sum().
|
inline |
compute the number of free parameters
Definition at line 176 of file STK_ModelBernoulli_pj.h.
References STK::IMultiStatModel< ModelBernoulli_pj< Data_, WColVector_ > >::p_data().
void STK::ModelBernoulli_pj< Data_, WColVector_ >::computeParameters | ( | ) |
compute the parameters
Definition at line 203 of file STK_ModelBernoulli_pj.h.
References STK::binaryNA_, STK::Arithmetic< Type >::NA(), and STK::sum().
void STK::ModelBernoulli_pj< Data_, WColVector_ >::computeParameters | ( | WColVector const & | weights | ) |
compute the weighted parameters
weights | the weights of the samples |
Definition at line 218 of file STK_ModelBernoulli_pj.h.
References STK::binaryNA_, STK::Arithmetic< Type >::NA(), and STK::sum().
|
inline |
vector of the log probabilities of the reversed observations
Definition at line 173 of file STK_ModelBernoulli_pj.h.
References STK::IMultiStatModel< ModelBernoulli_pj< Data_, WColVector_ > >::param().
|
inline |
vector of the log probabilities of the observations
Definition at line 171 of file STK_ModelBernoulli_pj.h.
References STK::IMultiStatModel< ModelBernoulli_pj< Data_, WColVector_ > >::param().
|
inline |
Definition at line 169 of file STK_ModelBernoulli_pj.h.
References STK::IMultiStatModel< ModelBernoulli_pj< Data_, WColVector_ > >::param().
void STK::ModelBernoulli_pj< Data_, WColVector_ >::writeParametersImpl | ( | ostream & | os | ) | const |
Write the parameters on the output stream os.
Definition at line 237 of file STK_ModelBernoulli_pj.h.
References _T.