Show
Ignore:
Timestamp:
02/16/09 10:02:08 (15 years ago)
Author:
smidl
Message:

Changes in the very root classes!
* rv and rvc are no longer compulsory,
* samplecond does not return ll
* BM has drv

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • doc/html/mixef_8h-source.html

    r269 r270  
    4646<a name="l00062"></a>00062                 } 
    4747<a name="l00063"></a>00063                 <span class="comment">// last in the product is the weight</span> 
    48 <a name="l00064"></a>00064                 epdfs ( <a class="code" href="classbdm_1_1MixEF.html#38ca1d86e977d1c38810a3c95bf074a5" title="Number of components.">n</a> ) =&amp; ( <a class="code" href="classbdm_1_1MixEF.html#e39faa70cebadc3296bd249040105e86" title="Statistics for weights.">weights</a>.<a class="code" href="classbdm_1_1multiBM.html#98c22316ecfef589989baca261713c8d" title="Returns a reference to the epdf representing posterior density on parameters.">_epdf</a>() ); 
     48<a name="l00064"></a>00064                 epdfs ( <a class="code" href="classbdm_1_1MixEF.html#38ca1d86e977d1c38810a3c95bf074a5" title="Number of components.">n</a> ) =&amp; ( <a class="code" href="classbdm_1_1MixEF.html#e39faa70cebadc3296bd249040105e86" title="Statistics for weights.">weights</a>.<a class="code" href="classbdm_1_1multiBM.html#98c22316ecfef589989baca261713c8d">_epdf</a>() ); 
    4949<a name="l00065"></a>00065                 <a class="code" href="classbdm_1_1MixEF.html#9413fb7f1836237aac807fb9f245e4f6" title="Posterior on component parameters.">est</a> = <span class="keyword">new</span> <a class="code" href="classbdm_1_1eprod.html" title="Product of independent epdfs. For dependent pdfs, use mprod.">eprod</a> ( epdfs ); 
    5050<a name="l00066"></a>00066         } 
     
    5252<a name="l00068"></a>00068 <span class="keyword">public</span>: 
    5353<a name="l00070"></a><a class="code" href="classbdm_1_1MixEF.html#4efe67d414ff34a1e7534004fd061241">00070</a>         <a class="code" href="classbdm_1_1MixEF.html#0266854387338ba757e6192d62907984" title="Constructor of empty mixture.">MixEF</a> ( <span class="keyword">const</span> Array&lt;BMEF*&gt; &amp;Coms0, <span class="keyword">const</span> vec &amp;alpha0 ) : 
    54 <a name="l00071"></a>00071                         <a class="code" href="classbdm_1_1BMEF.html" title="Estimator for Exponential family.">BMEF</a> ( <a class="code" href="classbdm_1_1RV.html" title="Class representing variables, most often random variables.">RV</a>() ), <a class="code" href="classbdm_1_1MixEF.html#38ca1d86e977d1c38810a3c95bf074a5" title="Number of components.">n</a> ( Coms0.length() ), <a class="code" href="classbdm_1_1MixEF.html#90c21ab5a2af56d4b49e2eaef6eccc08" title="Models for Components of .">Coms</a> ( <a class="code" href="classbdm_1_1MixEF.html#38ca1d86e977d1c38810a3c95bf074a5" title="Number of components.">n</a> ), 
    55 <a name="l00072"></a>00072                         <a class="code" href="classbdm_1_1MixEF.html#e39faa70cebadc3296bd249040105e86" title="Statistics for weights.">weights</a> ( <a class="code" href="classbdm_1_1RV.html" title="Class representing variables, most often random variables.">RV</a> ( <span class="stringliteral">"{w }"</span>, vec_1 ( <a class="code" href="classbdm_1_1MixEF.html#38ca1d86e977d1c38810a3c95bf074a5" title="Number of components.">n</a> ) ),alpha0 ), <a class="code" href="classbdm_1_1MixEF.html#a2376ddadb7573532404452d0c2dd28a" title="Flag for a method that is used in the inference.">method</a>(QB) { 
     54<a name="l00071"></a>00071                         <a class="code" href="classbdm_1_1BMEF.html" title="Estimator for Exponential family.">BMEF</a> ( ), <a class="code" href="classbdm_1_1MixEF.html#38ca1d86e977d1c38810a3c95bf074a5" title="Number of components.">n</a> ( Coms0.length() ), <a class="code" href="classbdm_1_1MixEF.html#90c21ab5a2af56d4b49e2eaef6eccc08" title="Models for Components of .">Coms</a> ( <a class="code" href="classbdm_1_1MixEF.html#38ca1d86e977d1c38810a3c95bf074a5" title="Number of components.">n</a> ), 
     55<a name="l00072"></a>00072                         <a class="code" href="classbdm_1_1MixEF.html#e39faa70cebadc3296bd249040105e86" title="Statistics for weights.">weights</a> (), <a class="code" href="classbdm_1_1MixEF.html#a2376ddadb7573532404452d0c2dd28a" title="Flag for a method that is used in the inference.">method</a>(QB) { 
    5656<a name="l00073"></a>00073         <span class="comment">//      it_assert_debug ( n&gt;0,"MixEF::MixEF : Empty Component list" );</span> 
    5757<a name="l00074"></a>00074  
     
    6060<a name="l00077"></a>00077         }; 
    6161<a name="l00079"></a><a class="code" href="classbdm_1_1MixEF.html#0266854387338ba757e6192d62907984">00079</a>         <a class="code" href="classbdm_1_1MixEF.html#0266854387338ba757e6192d62907984" title="Constructor of empty mixture.">MixEF</a> () : 
    62 <a name="l00080"></a>00080                         <a class="code" href="classbdm_1_1BMEF.html" title="Estimator for Exponential family.">BMEF</a> ( <a class="code" href="classbdm_1_1RV.html" title="Class representing variables, most often random variables.">RV</a>() ), <a class="code" href="classbdm_1_1MixEF.html#38ca1d86e977d1c38810a3c95bf074a5" title="Number of components.">n</a> ( 0 ), <a class="code" href="classbdm_1_1MixEF.html#90c21ab5a2af56d4b49e2eaef6eccc08" title="Models for Components of .">Coms</a> ( 0 ), 
    63 <a name="l00081"></a>00081                         <a class="code" href="classbdm_1_1MixEF.html#e39faa70cebadc3296bd249040105e86" title="Statistics for weights.">weights</a> ( <a class="code" href="classbdm_1_1RV.html" title="Class representing variables, most often random variables.">RV</a> ( <span class="stringliteral">"{w }"</span>, vec_1 ( 0 ) ),vec ( 0 ) ),<a class="code" href="classbdm_1_1MixEF.html#a2376ddadb7573532404452d0c2dd28a" title="Flag for a method that is used in the inference.">method</a>(QB) {<a class="code" href="classbdm_1_1MixEF.html#d74a8d1370c63c93ec554908ae3e6006" title="Auxiliary function for use in constructors.">build_est</a>();} 
    64 <a name="l00083"></a><a class="code" href="classbdm_1_1MixEF.html#9577de85c3e3481f7c0e23cf8f87c482">00083</a>         <a class="code" href="classbdm_1_1MixEF.html#0266854387338ba757e6192d62907984" title="Constructor of empty mixture.">MixEF</a>(<span class="keyword">const</span> <a class="code" href="classbdm_1_1MixEF.html" title="Mixture of Exponential Family Densities.">MixEF</a> &amp;M2): <a class="code" href="classbdm_1_1BMEF.html" title="Estimator for Exponential family.">BMEF</a> ( <a class="code" href="classbdm_1_1RV.html" title="Class representing variables, most often random variables.">RV</a>() ), <a class="code" href="classbdm_1_1MixEF.html#38ca1d86e977d1c38810a3c95bf074a5" title="Number of components.">n</a> ( M2.<a class="code" href="classbdm_1_1MixEF.html#38ca1d86e977d1c38810a3c95bf074a5" title="Number of components.">n</a> ), <a class="code" href="classbdm_1_1MixEF.html#90c21ab5a2af56d4b49e2eaef6eccc08" title="Models for Components of .">Coms</a> ( <a class="code" href="classbdm_1_1MixEF.html#38ca1d86e977d1c38810a3c95bf074a5" title="Number of components.">n</a> ), 
     62<a name="l00080"></a>00080                         <a class="code" href="classbdm_1_1BMEF.html" title="Estimator for Exponential family.">BMEF</a> ( ), <a class="code" href="classbdm_1_1MixEF.html#38ca1d86e977d1c38810a3c95bf074a5" title="Number of components.">n</a> ( 0 ), <a class="code" href="classbdm_1_1MixEF.html#90c21ab5a2af56d4b49e2eaef6eccc08" title="Models for Components of .">Coms</a> ( 0 ), 
     63<a name="l00081"></a>00081                         <a class="code" href="classbdm_1_1MixEF.html#e39faa70cebadc3296bd249040105e86" title="Statistics for weights.">weights</a> (),<a class="code" href="classbdm_1_1MixEF.html#a2376ddadb7573532404452d0c2dd28a" title="Flag for a method that is used in the inference.">method</a>(QB) {<a class="code" href="classbdm_1_1MixEF.html#d74a8d1370c63c93ec554908ae3e6006" title="Auxiliary function for use in constructors.">build_est</a>();} 
     64<a name="l00083"></a><a class="code" href="classbdm_1_1MixEF.html#9577de85c3e3481f7c0e23cf8f87c482">00083</a>         <a class="code" href="classbdm_1_1MixEF.html#0266854387338ba757e6192d62907984" title="Constructor of empty mixture.">MixEF</a>(<span class="keyword">const</span> <a class="code" href="classbdm_1_1MixEF.html" title="Mixture of Exponential Family Densities.">MixEF</a> &amp;M2): <a class="code" href="classbdm_1_1BMEF.html" title="Estimator for Exponential family.">BMEF</a> ( ), <a class="code" href="classbdm_1_1MixEF.html#38ca1d86e977d1c38810a3c95bf074a5" title="Number of components.">n</a> ( M2.<a class="code" href="classbdm_1_1MixEF.html#38ca1d86e977d1c38810a3c95bf074a5" title="Number of components.">n</a> ), <a class="code" href="classbdm_1_1MixEF.html#90c21ab5a2af56d4b49e2eaef6eccc08" title="Models for Components of .">Coms</a> ( <a class="code" href="classbdm_1_1MixEF.html#38ca1d86e977d1c38810a3c95bf074a5" title="Number of components.">n</a> ), 
    6565<a name="l00084"></a>00084                    <a class="code" href="classbdm_1_1MixEF.html#e39faa70cebadc3296bd249040105e86" title="Statistics for weights.">weights</a> ( M2.<a class="code" href="classbdm_1_1MixEF.html#e39faa70cebadc3296bd249040105e86" title="Statistics for weights.">weights</a> ), <a class="code" href="classbdm_1_1MixEF.html#a2376ddadb7573532404452d0c2dd28a" title="Flag for a method that is used in the inference.">method</a>(M2.<a class="code" href="classbdm_1_1MixEF.html#a2376ddadb7573532404452d0c2dd28a" title="Flag for a method that is used in the inference.">method</a>) { 
    6666<a name="l00085"></a>00085         <span class="comment">//      it_assert_debug ( n&gt;0,"MixEF::MixEF : Empty Component list" );</span> 
     
    7979<a name="l00104"></a>00104         <span class="keywordtype">void</span> bayesB ( <span class="keyword">const</span> mat &amp;dt, <span class="keyword">const</span> vec &amp;wData ); 
    8080<a name="l00105"></a>00105         <span class="keywordtype">double</span> <a class="code" href="classbdm_1_1MixEF.html#da724da464a75e07521941e430929efa">logpred</a> ( <span class="keyword">const</span> vec &amp;dt ) <span class="keyword">const</span>; 
    81 <a name="l00106"></a><a class="code" href="classbdm_1_1MixEF.html#33d0b3da1d10bf149d41ee74f6284a19">00106</a>         <span class="keyword">const</span> <a class="code" href="classbdm_1_1epdf.html" title="Probability density function with numerical statistics, e.g. posterior density.">epdf</a>&amp; <a class="code" href="classbdm_1_1MixEF.html#33d0b3da1d10bf149d41ee74f6284a19" title="Returns a reference to the epdf representing posterior density on parameters.">_epdf</a>()<span class="keyword"> const </span>{<span class="keywordflow">return</span> *<a class="code" href="classbdm_1_1MixEF.html#9413fb7f1836237aac807fb9f245e4f6" title="Posterior on component parameters.">est</a>;} 
    82 <a name="l00107"></a><a class="code" href="classbdm_1_1MixEF.html#ea8be6f0703d87b7c4c3e77fd07e28c8">00107</a>         <span class="keyword">const</span> <a class="code" href="classbdm_1_1eprod.html" title="Product of independent epdfs. For dependent pdfs, use mprod.">eprod</a>* <a class="code" href="classbdm_1_1MixEF.html#ea8be6f0703d87b7c4c3e77fd07e28c8" title="Returns a pointer to the epdf representing posterior density on parameters. Use with...">_e</a>()<span class="keyword"> const </span>{<span class="keywordflow">return</span> <a class="code" href="classbdm_1_1MixEF.html#9413fb7f1836237aac807fb9f245e4f6" title="Posterior on component parameters.">est</a>;} 
    83 <a name="l00108"></a>00108         <a class="code" href="classbdm_1_1emix.html" title="Mixture of epdfs.">emix</a>* <a class="code" href="classbdm_1_1MixEF.html#5105973c0f790f08d1dfb79c2a3f6e1c" title="Constructs a predictive density (marginal density on data).">predictor</a>(<span class="keyword">const</span> <a class="code" href="classbdm_1_1RV.html" title="Class representing variables, most often random variables.">RV</a> &amp;<a class="code" href="classbdm_1_1BM.html#18d6db4af8ee42077741d9e3618153ca" title="Random variable of the posterior.">rv</a>) <span class="keyword">const</span>; 
    84 <a name="l00110"></a>00110         <span class="keywordtype">void</span> <a class="code" href="classbdm_1_1MixEF.html#f0dfb4375fef4e61c4cb062e5bac7c8c" title="Flatten the density as if it was not estimated from the data.">flatten</a>(<span class="keyword">const</span> <a class="code" href="classbdm_1_1BMEF.html" title="Estimator for Exponential family.">BMEF</a>* M2); 
     81<a name="l00106"></a>00106         <span class="keyword">const</span> epdf&amp; _epdf()<span class="keyword"> const </span>{<span class="keywordflow">return</span> *<a class="code" href="classbdm_1_1MixEF.html#9413fb7f1836237aac807fb9f245e4f6" title="Posterior on component parameters.">est</a>;} 
     82<a name="l00107"></a>00107         <span class="keyword">const</span> eprod* _e()<span class="keyword"> const </span>{<span class="keywordflow">return</span> <a class="code" href="classbdm_1_1MixEF.html#9413fb7f1836237aac807fb9f245e4f6" title="Posterior on component parameters.">est</a>;} 
     83<a name="l00108"></a>00108         emix* <a class="code" href="classbdm_1_1MixEF.html#edc50e9640f049b846084748b18469a2" title="Constructs a predictive density .">epredictor</a>() <span class="keyword">const</span>; 
     84<a name="l00110"></a>00110         <span class="keywordtype">void</span> <a class="code" href="classbdm_1_1MixEF.html#f0dfb4375fef4e61c4cb062e5bac7c8c" title="Flatten the density as if it was not estimated from the data.">flatten</a>(<span class="keyword">const</span> <a class="code" href="classbdm_1_1BMEF.html#2def512872ed8a4fc3b702371ec0be55" title="Default constructor (=empty constructor).">BMEF</a>* M2); 
    8585<a name="l00112"></a><a class="code" href="classbdm_1_1MixEF.html#251ef6fc51757712693da5faae5317c9">00112</a>         <a class="code" href="classbdm_1_1BMEF.html" title="Estimator for Exponential family.">BMEF</a>* <a class="code" href="classbdm_1_1MixEF.html#251ef6fc51757712693da5faae5317c9" title="Access function.">_Coms</a>(<span class="keywordtype">int</span> i){<span class="keywordflow">return</span> <a class="code" href="classbdm_1_1MixEF.html#90c21ab5a2af56d4b49e2eaef6eccc08" title="Models for Components of .">Coms</a>(i);} 
    8686<a name="l00113"></a>00113          
     
    9393<a name="l00121"></a>00121  
    9494</pre></div></div> 
    95 <hr size="1"><address style="text-align: right;"><small>Generated on Wed Feb 11 10:20:05 2009 for mixpp by&nbsp; 
     95<hr size="1"><address style="text-align: right;"><small>Generated on Wed Feb 11 23:33:55 2009 for mixpp by&nbsp; 
    9696<a href="http://www.doxygen.org/index.html"> 
    9797<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.6 </small></address>