Public Member Functions

GaussPrior Class Reference

gaussian (normal) prior More...

#include <prior.h>

Inheritance diagram for GaussPrior:
PsiPrior

List of all members.

Public Member Functions

 GaussPrior (double mean, double sd)
 initialize prior to have mean mean and standard deviation sd
 GaussPrior (const GaussPrior &original)
 copy contructor
double pdf (double x) const
 return pdf of the prior at position x
double dpdf (double x)
 return derivative of the prior at position x
double rand (void)
 draw a random number
PsiPriorclone (void) const
 clone by value
double mean (void) const
 mean
double std (void) const
 return standard deviation
void shrink (double xmin, double xmax)
 shrink the prior if it is broader than the range between xmin and xmax
int get_code (void) const
 return the typcode of this prior
double cdf (double x) const
 return the typcode of this prior
double getprm (unsigned int prm) const
double ppf (double p, double start=NULL) const

Detailed Description

gaussian (normal) prior

This defines a gaussian prior on the entire real axis. It's pdf is defined by the normal

\[ f(x) = \frac{1}{\sqrt{2 \pi}\sigma} \exp \left( - \frac{(x-\mu)^2}{2\sigma^2} \right). \]


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