#include <UniformDistribution.h>
Inheritance diagram for PLearn::UniformDistribution:
Public Member Functions | |
UniformDistribution () | |
Default constructor. | |
virtual void | build () |
Simply call inherited::build() then build_(). | |
virtual void | makeDeepCopyFromShallowCopy (map< const void *, void * > &copies) |
Transform a shallow copy into a deep copy. | |
PLEARN_DECLARE_OBJECT (UniformDistribution) | |
virtual int | inputsize () const |
Overridden so that it does not need a training set. | |
virtual real | log_density (const Vec &x) const |
Return log of probability density log(p(x)). | |
virtual real | survival_fn (const Vec &x) const |
Return survival fn = P(X>x). | |
virtual real | cdf (const Vec &x) const |
Return survival fn = P(X<x). | |
virtual void | expectation (Vec &mu) const |
Return E[X]. | |
virtual void | variance (Mat &cov) const |
Return Var[X]. | |
virtual void | resetGenerator (long g_seed) const |
Reset the random number generator used by generate() using the given seed. | |
virtual void | generate (Vec &x) const |
Return a pseudo-random sample generated from the distribution. | |
Public Attributes | |
Vec | max |
Vec | min |
Static Protected Member Functions | |
void | declareOptions (OptionList &ol) |
Declare this class' options. | |
Private Types | |
typedef UnconditionalDistribution | inherited |
Private Member Functions | |
void | build_ () |
This does the actual building. |
|
Reimplemented from PLearn::UnconditionalDistribution. Definition at line 57 of file UniformDistribution.h. |
|
Default constructor.
Definition at line 52 of file UniformDistribution.cc. References max, min, and PLearn::TVec< T >::resize(). |
|
Simply call inherited::build() then build_().
Reimplemented from PLearn::UnconditionalDistribution. Definition at line 87 of file UniformDistribution.cc. References build_(). |
|
This does the actual building.
Reimplemented from PLearn::UnconditionalDistribution. Definition at line 96 of file UniformDistribution.cc. References PLearn::TVec< T >::length(), max, min, and PLERROR. Referenced by build(). |
|
Return survival fn = P(X<x).
Reimplemented from PLearn::PDistribution. Definition at line 121 of file UniformDistribution.cc. References PLERROR. |
|
Declare this class' options.
Reimplemented from PLearn::UnconditionalDistribution. Definition at line 72 of file UniformDistribution.cc. References PLearn::declareOption(), and PLearn::OptionList. |
|
Return E[X].
Reimplemented from PLearn::PDistribution. Definition at line 129 of file UniformDistribution.cc. References PLERROR. |
|
Return a pseudo-random sample generated from the distribution.
Reimplemented from PLearn::PDistribution. Definition at line 137 of file UniformDistribution.cc. References PLearn::bounded_uniform(), PLearn::TVec< T >::length(), max, min, and x. |
|
Overridden so that it does not need a training set.
Reimplemented from PLearn::PLearner. Definition at line 148 of file UniformDistribution.cc. References PLearn::TVec< T >::length(), and min. |
|
Return log of probability density log(p(x)).
Reimplemented from PLearn::PDistribution. Definition at line 155 of file UniformDistribution.cc. References PLERROR. |
|
Transform a shallow copy into a deep copy.
Reimplemented from PLearn::UnconditionalDistribution. Definition at line 163 of file UniformDistribution.cc. References PLERROR. |
|
|
|
Reset the random number generator used by generate() using the given seed.
Reimplemented from PLearn::PDistribution. Definition at line 180 of file UniformDistribution.cc. References PLearn::manual_seed(). |
|
Return survival fn = P(X>x).
Reimplemented from PLearn::PDistribution. Definition at line 188 of file UniformDistribution.cc. References PLERROR. |
|
Return Var[X].
Reimplemented from PLearn::PDistribution. Definition at line 196 of file UniformDistribution.cc. References PLearn::Mat, and PLERROR. |
|
Definition at line 71 of file UniformDistribution.h. Referenced by build_(), generate(), and UniformDistribution(). |
|
Definition at line 72 of file UniformDistribution.h. Referenced by build_(), generate(), inputsize(), and UniformDistribution(). |