Show
Ignore:
Timestamp:
06/09/10 18:35:14 (14 years ago)
Author:
mido
Message:

patch of documentation - all conditional pdfs revised

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • library/bdm/stat/exp_family.h

    r1066 r1068  
    124124}; 
    125125 
    126 /*! Dirac delta density with predefined transformation 
     126/*! \brief Dirac delta density with predefined transformation 
    127127 
    128128Density of the type:\f[ f(x_t | y_t) = \delta (x_t - g(y_t)) \f] 
     
    141141        return std::numeric_limits< double >::max(); 
    142142    } 
     143 
     144    /*! Create object from the following structure 
     145 
     146    \code 
     147    class = 'mgdirac'; 
     148    g = function bdm::fnc;      % any offspring of fnc, bdm::fnc::from_setting 
     149    --- inherited fields --- 
     150    bdm::pdf::from_setting 
     151    \endcode 
     152    */ 
    143153    void from_setting(const Setting& set); 
    144154    void to_setting(Setting &set) const; 
     
    666676UIREGISTER ( eBeta ); 
    667677 
    668 /*! Random Walk on Dirichlet 
     678/*! \brief Random Walk on Dirichlet 
     679 
    669680Using simple assignment 
    670681 \f[ \beta = rvc / k + \beta_c \f] 
     
    676687 By default is it set to 0.1; 
    677688*/ 
    678  
    679689class mDirich: public pdf_internal<eDirich> { 
    680690protected: 
     
    690700        _beta =  val / k + betac; 
    691701    }; 
    692     /*! Create Dirichlet random walk 
    693     \f[ f(rv|rvc) = Di(rvc*k) \f] 
    694     from structure 
     702 
     703    /*! Create object from the following structure 
    695704    \code 
    696705    class = 'mDirich'; 
    697     k = 1;                      // multiplicative constant k 
     706    k = 1;                      % multiplicative constant k 
    698707    --- optional --- 
    699     rv = RV({'name'},size)      // description of RV 
    700     beta0 = [];                 // initial value of beta 
    701     betac = [];                 // initial value of beta 
     708    beta0 = [...];              % initial values of beta 
     709    betac = [...];              % initial values of beta stabilizing coefficients 
     710    --- inherited fields --- 
     711    bdm::pdf::from_setting 
     712    \endcode 
     713    fulfilling form  \f[ f(rv|rvc) = Di(rvc*k) \f] 
     714 
     715    If the optional fields are not given, they will be filled as follows: 
     716    \code 
     717    beta0 = [1,1,1,...];                 
     718    betac = 0.1 * [1,1,1,...]; 
    702719    \endcode 
    703720    */ 
     
    709726 
    710727/*! \brief Random Walk with vector Beta distribution 
     728 
    711729Using simple assignment 
    712730\f{eqnarray*} 
     
    733751    }; 
    734752 
    735     /*! Create Beta random walk 
    736     \f[ f(rv|rvc) = \prod Beta(rvc,k) \f] 
    737     from structure 
     753    /*! Create object from the following structure 
    738754    \code 
    739755    class = 'mBeta'; 
    740     k = 1;                      // multiplicative constant k 
    741     --- optional --- 
    742     rv = RV({'name'},size)      // description of RV 
    743     beta  = [];                 // initial value of beta 
    744     betac = [];                 // initial value of beta stabilizing constant 
     756    k = [...];          % vector of multiplicative constants k 
     757    --- optional fields --- 
     758    beta  = [...];      % initial values of beta 
     759    betac = [...];      % initial values of beta stabilizing constants 
     760    --- inherited fields --- 
     761    bdm::pdf::from_setting 
    745762    \endcode 
     763    fulfilling form \f[ f(rv|rvc) = \prod Beta(rvc,k) \f] 
     764 
     765    If the optional fields are not given, they will be filled as follows: 
     766    \code 
     767    beta  = [1,1,1,...]; 
     768    betac = 0.1 * [1,1,1,...]; 
     769    \endcode 
     770     
    746771    */ 
    747772    void from_setting ( const Setting &set ); 
     
    928953*/ 
    929954 
    930 //!  Uniform distributed density on a rectangular support 
    931  
     955//! \brief Uniform distributed density on a rectangular support 
    932956class euni: public epdf { 
    933957protected: 
     
    9761000        return ( pow ( high, 2 ) + pow ( low, 2 ) + elem_mult ( high, low ) ) / 3.0; 
    9771001    } 
    978     /*! Create Uniform density 
    979     \f[ f(rv) = U(low,high) \f] 
    980     from structure 
     1002 
     1003 
     1004     /*! Create object from the following structure 
    9811005     \code 
     1006     
    9821007     class = 'euni' 
    983      high = [...];          // vector of upper bounds 
    984      low = [...];           // vector of lower bounds 
    985      rv = RV({'name'});     // description of RV 
     1008     high = [...];          % vector of upper bounds 
     1009     low = [...];           % vector of lower bounds      
     1010      rv = RV({'names',...},[sizes,...],[times,...]);   % description of RV 
     1011     --- inherited fields --- 
     1012     bdm::epdf::from_setting 
    9861013     \endcode 
     1014 
     1015     fulfilling form \f[ f(rv) = U(low,high) \f] 
    9871016     */ 
    9881017    void from_setting ( const Setting &set ); 
     
    10031032        iepdf.set_parameters ( mea - delta, mea + delta ); 
    10041033    } 
    1005     //! load from 
     1034 
     1035    /*! Create object from the following structure 
     1036    \code 
     1037    class = 'mguni'; 
     1038    mean = function bdm::fnc;       % any offspring of fnc, bdm::fnc::from_setting 
     1039    delta = [...];                  % distance from mean to both sides 
     1040    --- inherited fields --- 
     1041    bdm::pdf::from_setting 
     1042    \endcode 
     1043    */ 
    10061044    void from_setting ( const Setting &set ) { 
    10071045        pdf::from_setting ( set ); //reads rv and rvc 
     
    12041242 
    12051243 
    1206 /*! (Approximate) Student t density with linear function of mean value 
     1244/*! \brief (Approximate) Student t density with linear function of mean value 
    12071245 
    12081246The internal epdf of this class is of the type of a Gaussian (enorm). 
     
    12711309        _beta = k / val; 
    12721310    }; 
    1273     /*! Create Gamma density with conditional mean value 
    1274     \f[ f(rv|rvc) = \Gamma(k, k/rvc) \f] 
    1275     from structure 
     1311 
     1312    /*! Create object from the following structure 
    12761313    \code 
    1277       class = 'mgamma'; 
    1278       beta = [...];          // vector of initial alpha 
    1279       k = 1.1;               // multiplicative constant k 
    1280       rv = RV({'name'})      // description of RV 
    1281       rvc = RV({'name'})     // description of RV in condition 
    1282      \endcode 
     1314    class = 'mgamma';     
     1315    beta = [...];      % vector of initial beta 
     1316    k = x;             %  multiplicative scalar constant k 
     1317    --- inherited fields --- 
     1318    bdm::pdf::from_setting 
     1319    \endcode 
     1320    fulfilling form \f[ f(rv|rvc) = \Gamma(k, k/rvc) \f] 
    12831321    */ 
    12841322    void from_setting ( const Setting &set ); 
     
    13401378    }; 
    13411379}; 
    1342  
    13431380 
    13441381/*! 
     
    13691406    }; 
    13701407 
    1371     void     validate () { 
     1408    void validate () { 
    13721409        mgamma::validate(); 
    13731410        dimc = dimension(); 
     
    14201457    }; 
    14211458 
    1422  
    1423     /*! Create inverse-Gamma density with conditional mean value 
    1424     \f[ f(rv|rvc) = i\Gamma(k, k/(rvc^l \circ ref^{(1-l)}) \f] 
    1425     from structure 
     1459    /*! Create object from the following structure 
    14261460    \code 
    14271461    class = 'migamma_ref'; 
    1428     ref = [1e-5; 1e-5; 1e-2 1e-3];            // reference vector 
    1429     l = 0.999;                                // constant l 
    1430     k = 0.1;                                  // constant k 
    1431     rv = RV({'name'})                         // description of RV 
    1432     rvc = RV({'name'})                        // description of RV in condition 
     1462    ref = [...];           % reference vector 
     1463    l = [];                % constant scalar l 
     1464    k = [];                % constant scalar k     
     1465    --- inherited fields --- 
     1466    bdm::migamma::from_setting 
    14331467    \endcode 
     1468    fulfilling form \f[ f(rv|rvc) = i\Gamma(k, k/(rvc^l \circ ref^{(1-l)}) \f] 
    14341469     */ 
    14351470    void from_setting ( const Setting &set ); 
     
    14421477SHAREDPTR ( migamma_ref ); 
    14431478 
    1444 /*! Log-Normal probability density 
    1445  only allow diagonal covariances! 
     1479/*! \brief Log-Normal probability density - it allows only diagonal covariances! 
    14461480 
    14471481Density of the form \f$ \log(x)\sim \mathcal{N}(\mu,\sigma^2) \f$ , i.e. 
     
    14991533    }; 
    15001534 
    1501     /*! Create logNormal random Walk 
    1502     \f[ f(rv|rvc) = log\mathcal{N}( \log(rvc)-0.5\log(k^2+1), k I) \f] 
    1503     from structure 
     1535    /*! Create object from the following structure 
    15041536    \code 
    15051537    class = 'mlognorm'; 
    1506     k   = 0.1;               // "variance" k 
    1507     mu0 = 0.1;               // Initial value of mean 
    1508     rv  = RV({'name'})       // description of RV 
    1509     rvc = RV({'name'})       // description of RV in condition 
     1538    k   = [];               % "variance" k 
     1539    mu0 = [];               % initial value of mean 
     1540    --- inherited fields --- 
     1541    bdm::pdf_internal<elognorm>::from_setting 
    15101542    \endcode 
     1543    fulfilling form \f[ f(rv|rvc) = log\mathcal{N}( \log(rvc)-0.5\log(k^2+1), k I) \f] 
    15111544    */ 
    15121545    void from_setting ( const Setting &set ); 
     
    15181551SHAREDPTR ( mlognorm ); 
    15191552 
    1520 /*! inverse Wishart density defined on Choleski decomposition 
    1521  
     1553/*! \brief Inverse Wishart density defined on Choleski decomposition 
    15221554*/ 
    15231555class eWishartCh : public epdf {