Show
Ignore:
Timestamp:
09/13/09 23:15:31 (15 years ago)
Author:
smidl
Message:

doc, sorted related pages

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • library/doc/html/classbdm_1_1ARX.html

    r614 r616  
    7474<p>Linear Autoregressive model with Gaussian noise.   
    7575<a href="#_details">More...</a></p> 
     76<hr/><a name="_details"></a><h2>Detailed Description</h2> 
     77<p>Linear Autoregressive model with Gaussian noise. </p> 
     78<p>Regression of the following kind: </p> 
     79<p class="formulaDsp"> 
     80<img class="formulaDsp" alt="\[ y_t = \theta_1 \psi_1 + \theta_2 + \psi_2 +\ldots + \theta_n \psi_n + r e_t \]" src="form_28.png"/> 
     81</p> 
     82<p> where unknown parameters <code>rv</code> are <img class="formulaInl" alt="$[\theta r]$" src="form_29.png"/>, regression vector <img class="formulaInl" alt="$\psi=\psi(y_{1:t},u_{1:t})$" src="form_30.png"/> is a known function of past outputs and exogeneous variables <img class="formulaInl" alt="$u_t$" src="form_31.png"/>. Distrubances <img class="formulaInl" alt="$e_t$" src="form_32.png"/> are supposed to be normally distributed: </p> 
     83<p class="formulaDsp"> 
     84<img class="formulaDsp" alt="\[ e_t \sim \mathcal{N}(0,1). \]" src="form_33.png"/> 
     85</p> 
     86<p>See <a class="el" href="tut_arx.html">Theory of ARX model estimation</a> for mathematical treatment.</p> 
     87<p>The easiest way how to use the class is: </p> 
     88<div class="fragment"><pre class="fragment"><span class="preprocessor">#include &quot;<a class="code" href="arx_8h.html" title="Bayesian Filtering for generalized autoregressive (ARX) model.">estim/arx.h</a>&quot;</span> 
     89<span class="keyword">using namespace </span>bdm; 
     90 
     91<span class="comment">// estimation of AR(0) model</span> 
     92<span class="keywordtype">int</span> main() { 
     93        <span class="comment">//prior</span> 
     94        mat V0 = 0.00001 * eye ( 2 ); 
     95        V0 ( 0, 0 ) = 0.1; <span class="comment">//</span> 
     96        ARX Ar; 
     97        Ar.set_statistics ( 1, V0 ); <span class="comment">//nu is default (set to have finite moments)</span> 
     98        <span class="comment">// forgetting is default: 1.0</span> 
     99        mat Data = concat_vertical ( randn ( 1, 100 ), ones ( 1, 100 ) ); 
     100        Ar.bayesB ( Data ); 
     101 
     102        cout &lt;&lt; <span class="stringliteral">&quot;Expected value of Theta is: &quot;</span> &lt;&lt; Ar.posterior().mean() &lt;&lt; endl; 
     103} 
     104</pre></div><dl class="todo"><dt><b><a class="el" href="todo.html#_todo000001">Todo:</a></b></dt><dd>sort out constant terms - bayes should accept vec without additional 1s </dd></dl> 
    76105 
    77106<p><code>#include &lt;<a class="el" href="arx_8h_source.html">arx.h</a>&gt;</code></p> 
     
    227256<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Flags for logging - same size as LIDs, each entry correspond to the same in LIDs. <br/></td></tr> 
    228257</table> 
    229 <hr/><a name="_details"></a><h2>Detailed Description</h2> 
    230 <p>Linear Autoregressive model with Gaussian noise. </p> 
    231 <p>Regression of the following kind: </p> 
    232 <p class="formulaDsp"> 
    233 <img class="formulaDsp" alt="\[ y_t = \theta_1 \psi_1 + \theta_2 + \psi_2 +\ldots + \theta_n \psi_n + r e_t \]" src="form_28.png"/> 
    234 </p> 
    235 <p> where unknown parameters <code>rv</code> are <img class="formulaInl" alt="$[\theta r]$" src="form_29.png"/>, regression vector <img class="formulaInl" alt="$\psi=\psi(y_{1:t},u_{1:t})$" src="form_30.png"/> is a known function of past outputs and exogeneous variables <img class="formulaInl" alt="$u_t$" src="form_31.png"/>. Distrubances <img class="formulaInl" alt="$e_t$" src="form_32.png"/> are supposed to be normally distributed: </p> 
    236 <p class="formulaDsp"> 
    237 <img class="formulaDsp" alt="\[ e_t \sim \mathcal{N}(0,1). \]" src="form_33.png"/> 
    238 </p> 
    239 <p>See <a class="el" href="tut_arx.html">Theory of ARX model estimation</a> for mathematical treatment.</p> 
    240 <p>The easiest way how to use the class is: </p> 
    241 <div class="fragment"><pre class="fragment"><span class="preprocessor">#include &quot;<a class="code" href="arx_8h.html" title="Bayesian Filtering for generalized autoregressive (ARX) model.">estim/arx.h</a>&quot;</span> 
    242 <span class="keyword">using namespace </span>bdm; 
    243  
    244 <span class="comment">// estimation of AR(0) model</span> 
    245 <span class="keywordtype">int</span> main() { 
    246         <span class="comment">//prior</span> 
    247         mat V0 = 0.00001 * eye ( 2 ); 
    248         V0 ( 0, 0 ) = 0.1; <span class="comment">//</span> 
    249         ARX Ar; 
    250         Ar.set_statistics ( 1, V0 ); <span class="comment">//nu is default (set to have finite moments)</span> 
    251         <span class="comment">// forgetting is default: 1.0</span> 
    252         mat Data = concat_vertical ( randn ( 1, 100 ), ones ( 1, 100 ) ); 
    253         Ar.bayesB ( Data ); 
    254  
    255         cout &lt;&lt; <span class="stringliteral">&quot;Expected value of Theta is: &quot;</span> &lt;&lt; Ar.posterior().mean() &lt;&lt; endl; 
    256 } 
    257 </pre></div><dl class="todo"><dt><b><a class="el" href="todo.html#_todo000001">Todo:</a></b></dt><dd>sort out constant terms - bayes should accept vec without additional 1s </dd></dl> 
    258258<hr/><h2>Member Function Documentation</h2> 
    259259<a class="anchor" id="aca0b54c0997cfd567f49377af5def106"></a><!-- doxytag: member="bdm::ARX::_copy_" ref="aca0b54c0997cfd567f49377af5def106" args="() const " --> 
     
    458458</ul> 
    459459</div> 
    460 <hr size="1"/><address style="text-align: right;"><small>Generated on Sun Sep 13 22:40:43 2009 for mixpp by&nbsp; 
     460<hr size="1"/><address style="text-align: right;"><small>Generated on Sun Sep 13 23:08:56 2009 for mixpp by&nbsp; 
    461461<a href="http://www.doxygen.org/index.html"> 
    462462<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.1 </small></address>