Index: library/doc/html/classbdm_1_1PF.html
===================================================================
--- library/doc/html/classbdm_1_1PF.html (revision 632)
+++ library/doc/html/classbdm_1_1PF.html (revision 641)
@@ -84,12 +84,39 @@
 <tr><td colspan="2"><h2>Public Member Functions</h2></td></tr>
 <tr><td class="memItemLeft" align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#abf104b869b5df8dd4a14bbe430d40488">set_options</a> (const string &amp;opt)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a63282dc111d1afb32c194c955d966a15"></a><!-- doxytag: member="bdm::PF::bayes_gensmp" ref="a63282dc111d1afb32c194c955d966a15" args="()" -->
+virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a63282dc111d1afb32c194c955d966a15">bayes_gensmp</a> ()</td></tr>
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">bayes I - generate samples and add their weights to lls <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aec76b4d647ac7dc683d8c9a7b7611026"></a><!-- doxytag: member="bdm::PF::bayes_weights" ref="aec76b4d647ac7dc683d8c9a7b7611026" args="()" -->
+virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#aec76b4d647ac7dc683d8c9a7b7611026">bayes_weights</a> ()</td></tr>
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">bayes II - compute weights of the <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ac3443faad7159e742ef3cb0674a92634"></a><!-- doxytag: member="bdm::PF::do_resampling" ref="ac3443faad7159e742ef3cb0674a92634" args="()" -->
+virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#ac3443faad7159e742ef3cb0674a92634">do_resampling</a> ()</td></tr>
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">important part of particle filtering - decide if it is time to perform resampling <br/></td></tr>
 <tr><td class="memItemLeft" align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a638946eea22d4964bf9350286bb4efd8">bayes</a> (const vec &amp;dt)</td></tr>
 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Incremental Bayes rule.  <a href="#a638946eea22d4964bf9350286bb4efd8"></a><br/></td></tr>
-<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a78a9f6809827be1d9bfe215d03b1c6ed"></a><!-- doxytag: member="bdm::PF::__w" ref="a78a9f6809827be1d9bfe215d03b1c6ed" args="()" -->
-vec *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a78a9f6809827be1d9bfe215d03b1c6ed">__w</a> ()</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a37cb95af19c7bd13eb3ec61f25923463"></a><!-- doxytag: member="bdm::PF::__w" ref="a37cb95af19c7bd13eb3ec61f25923463" args="()" -->
+vec &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a37cb95af19c7bd13eb3ec61f25923463">__w</a> ()</td></tr>
 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">access function <br/></td></tr>
-<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a23c6a8f71f922023ab08dcb0487a86de"></a><!-- doxytag: member="bdm::PF::from_setting" ref="a23c6a8f71f922023ab08dcb0487a86de" args="(const Setting &amp;set)" -->
-void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1BM.html#a23c6a8f71f922023ab08dcb0487a86de">from_setting</a> (const Setting &amp;set)</td></tr>
-<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">This method arrange instance properties according the data stored in the Setting structure. <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a82d221d771cbc3c15a37cb358d759734"></a><!-- doxytag: member="bdm::PF::_lls" ref="a82d221d771cbc3c15a37cb358d759734" args="()" -->
+vec &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a82d221d771cbc3c15a37cb358d759734">_lls</a> ()</td></tr>
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">access function <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ab4e4023b749c33fc6d6b97d805338721"></a><!-- doxytag: member="bdm::PF::_resmethod" ref="ab4e4023b749c33fc6d6b97d805338721" args="() const " -->
+RESAMPLING_METHOD&nbsp;</td><td class="memItemRight" valign="bottom"><b>_resmethod</b> () const </td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aee9553da1a05671f94f30e0e94ff42cd"></a><!-- doxytag: member="bdm::PF::posterior" ref="aee9553da1a05671f94f30e0e94ff42cd" args="() const " -->
+const <a class="el" href="classbdm_1_1eEmp.html">eEmp</a> &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#aee9553da1a05671f94f30e0e94ff42cd">posterior</a> () const </td></tr>
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">access function <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a40d74160df73d152a9bcf044eac25663">from_setting</a> (const Setting &amp;set)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a30f6a71f3e56ce25e4e0ecafa0ffbd8d"></a><!-- doxytag: member="bdm::PF::resmethod_from_set" ref="a30f6a71f3e56ce25e4e0ecafa0ffbd8d" args="(const Setting &amp;set)" -->
+void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a30f6a71f3e56ce25e4e0ecafa0ffbd8d">resmethod_from_set</a> (const Setting &amp;set)</td></tr>
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">auxiliary function reading parameter 'resmethod' from configuration file <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a8ac867d4b88c2c6c73ae29d47f37d0bb"></a><!-- doxytag: member="bdm::PF::prior_from_set" ref="a8ac867d4b88c2c6c73ae29d47f37d0bb" args="(const Setting &amp;set)" -->
+void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a8ac867d4b88c2c6c73ae29d47f37d0bb">prior_from_set</a> (const Setting &amp;set)</td></tr>
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">load prior information from set and set internal structures accordingly <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a7ebbb12b5b01e8ac6985af0e04e0f0c2"></a><!-- doxytag: member="bdm::PF::validate" ref="a7ebbb12b5b01e8ac6985af0e04e0f0c2" args="()" -->
+void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a7ebbb12b5b01e8ac6985af0e04e0f0c2">validate</a> ()</td></tr>
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">This method TODO. <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a10fd6402c67ad3ee3a1a9a23fe91d7d7"></a><!-- doxytag: member="bdm::PF::resample" ref="a10fd6402c67ad3ee3a1a9a23fe91d7d7" args="(ivec &amp;ind)" -->
+void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a10fd6402c67ad3ee3a1a9a23fe91d7d7">resample</a> (ivec &amp;ind)</td></tr>
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">resample posterior density (from outside - see <a class="el" href="classbdm_1_1MPF.html" title="Marginalized Particle filter.">MPF</a>) <br/></td></tr>
 <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aaf0e6941ba5919cae1bc530e2181b109"></a><!-- doxytag: member="bdm::PF::to_string" ref="aaf0e6941ba5919cae1bc530e2181b109" args="()" -->
 virtual string&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1root.html#aaf0e6941ba5919cae1bc530e2181b109">to_string</a> ()</td></tr>
@@ -98,7 +125,4 @@
 virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1root.html#a67d954d255ede776eade7334d4895790">to_setting</a> (Setting &amp;set) const </td></tr>
 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">This method save all the instance properties into the Setting structure. <br/></td></tr>
-<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a1c314bd6d6dacb8ba78ea5eb88fd9516"></a><!-- doxytag: member="bdm::PF::validate" ref="a1c314bd6d6dacb8ba78ea5eb88fd9516" args="()" -->
-virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1root.html#a1c314bd6d6dacb8ba78ea5eb88fd9516">validate</a> ()</td></tr>
-<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">This method TODO. <br/></td></tr>
 <tr><td colspan="2"><div class="groupHeader">Constructors</div></td></tr>
 <tr><td colspan="2"><div class="groupText"><p><a class="anchor" id="amgrp559a25fdb98a7d1fd1c3771ac568d5e9"></a> </p>
@@ -106,8 +130,12 @@
 <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a297339fd48bc1cfd011d16603d54accb"></a><!-- doxytag: member="bdm::PF::PF" ref="a297339fd48bc1cfd011d16603d54accb" args="()" -->
 &nbsp;</td><td class="memItemRight" valign="bottom"><b>PF</b> ()</td></tr>
-<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a80b9b6b0506797c41b50b9bd236bc856"></a><!-- doxytag: member="bdm::PF::set_parameters" ref="a80b9b6b0506797c41b50b9bd236bc856" args="(mpdf *par0, mpdf *obs0, int n0, RESAMPLING_METHOD rm=SYSTEMATIC)" -->
-void&nbsp;</td><td class="memItemRight" valign="bottom"><b>set_parameters</b> (<a class="el" href="classbdm_1_1mpdf.html">mpdf</a> *par0, <a class="el" href="classbdm_1_1mpdf.html">mpdf</a> *obs0, int n0, RESAMPLING_METHOD rm=SYSTEMATIC)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a6b2a5ff7a9da0c881ecfc905e5643417"></a><!-- doxytag: member="bdm::PF::set_parameters" ref="a6b2a5ff7a9da0c881ecfc905e5643417" args="(int n0, double res_th0=0.5, RESAMPLING_METHOD rm=SYSTEMATIC)" -->
+void&nbsp;</td><td class="memItemRight" valign="bottom"><b>set_parameters</b> (int n0, double res_th0=0.5, RESAMPLING_METHOD rm=SYSTEMATIC)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a9e37481febc4061d3ff0f58f3f560b8d"></a><!-- doxytag: member="bdm::PF::set_model" ref="a9e37481febc4061d3ff0f58f3f560b8d" args="(shared_ptr&lt; mpdf &gt; par0, shared_ptr&lt; mpdf &gt; obs0)" -->
+void&nbsp;</td><td class="memItemRight" valign="bottom"><b>set_model</b> (<a class="el" href="classbdm_1_1shared__ptr.html">shared_ptr</a>&lt; <a class="el" href="classbdm_1_1mpdf.html">mpdf</a> &gt; par0, <a class="el" href="classbdm_1_1shared__ptr.html">shared_ptr</a>&lt; <a class="el" href="classbdm_1_1mpdf.html">mpdf</a> &gt; obs0)</td></tr>
 <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ac9a4df02d81ad3559caebeed74b16167"></a><!-- doxytag: member="bdm::PF::set_statistics" ref="ac9a4df02d81ad3559caebeed74b16167" args="(const vec w0, const epdf &amp;epdf0)" -->
 void&nbsp;</td><td class="memItemRight" valign="bottom"><b>set_statistics</b> (const vec w0, const <a class="el" href="classbdm_1_1epdf.html">epdf</a> &amp;epdf0)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a3027ebe66f806275e356eb7df9076173"></a><!-- doxytag: member="bdm::PF::set_statistics" ref="a3027ebe66f806275e356eb7df9076173" args="(const eEmp &amp;epdf0)" -->
+void&nbsp;</td><td class="memItemRight" valign="bottom"><b>set_statistics</b> (const <a class="el" href="classbdm_1_1eEmp.html">eEmp</a> &amp;epdf0)</td></tr>
 <tr><td colspan="2"><div class="groupHeader">Constructors</div></td></tr>
 <tr><td colspan="2"><div class="groupText"><p><a class="anchor" id="amgrp559a25fdb98a7d1fd1c3771ac568d5e9"></a> </p>
@@ -143,6 +171,4 @@
 <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a236b3abbcc93594fc97cd86d82c1a83f"></a><!-- doxytag: member="bdm::PF::set_evalll" ref="a236b3abbcc93594fc97cd86d82c1a83f" args="(bool evl0)" -->
 void&nbsp;</td><td class="memItemRight" valign="bottom"><b>set_evalll</b> (bool evl0)</td></tr>
-<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="abb7b0065d6cb722a66b371a8260121e1"></a><!-- doxytag: member="bdm::PF::posterior" ref="abb7b0065d6cb722a66b371a8260121e1" args="() const =0" -->
-virtual const <a class="el" href="classbdm_1_1epdf.html">epdf</a> &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><b>posterior</b> () const =0</td></tr>
 <tr><td colspan="2"><h2>Protected Attributes</h2></td></tr>
 <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aeeafaf9b8ad75fe62ee9fd6369e3f7fe"></a><!-- doxytag: member="bdm::PF::n" ref="aeeafaf9b8ad75fe62ee9fd6369e3f7fe" args="" -->
@@ -158,13 +184,17 @@
 Array&lt; vec &gt; &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a914bd66025692c4018dbd482cb3c47c1">_samples</a></td></tr>
 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">pointer into <code><a class="el" href="classbdm_1_1eEmp.html" title="Weighted empirical density.">eEmp</a></code> <br/></td></tr>
-<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a521e9621d3b5e1274275f323691afdaf"></a><!-- doxytag: member="bdm::PF::par" ref="a521e9621d3b5e1274275f323691afdaf" args="" -->
-<a class="el" href="classbdm_1_1mpdf.html">mpdf</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a521e9621d3b5e1274275f323691afdaf">par</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a0b7ffedb2051161df6c102881afe41ff"></a><!-- doxytag: member="bdm::PF::par" ref="a0b7ffedb2051161df6c102881afe41ff" args="" -->
+<a class="el" href="classbdm_1_1shared__ptr.html">shared_ptr</a>&lt; <a class="el" href="classbdm_1_1mpdf.html">mpdf</a> &gt;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a0b7ffedb2051161df6c102881afe41ff">par</a></td></tr>
 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Parameter evolution model. <br/></td></tr>
-<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ad6e7a62fba1e0a0d73c9b87f4fb683ec"></a><!-- doxytag: member="bdm::PF::obs" ref="ad6e7a62fba1e0a0d73c9b87f4fb683ec" args="" -->
-<a class="el" href="classbdm_1_1mpdf.html">mpdf</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#ad6e7a62fba1e0a0d73c9b87f4fb683ec">obs</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a77ed889e1b993df253e93059933d227d"></a><!-- doxytag: member="bdm::PF::obs" ref="a77ed889e1b993df253e93059933d227d" args="" -->
+<a class="el" href="classbdm_1_1shared__ptr.html">shared_ptr</a>&lt; <a class="el" href="classbdm_1_1mpdf.html">mpdf</a> &gt;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a77ed889e1b993df253e93059933d227d">obs</a></td></tr>
 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Observation model. <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a08cffd22d6e9501f283972245aeff8cd"></a><!-- doxytag: member="bdm::PF::lls" ref="a08cffd22d6e9501f283972245aeff8cd" args="" -->
+vec&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a08cffd22d6e9501f283972245aeff8cd">lls</a></td></tr>
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">internal structure storing loglikelihood of predictions <br/></td></tr>
 <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a9932c7c5865954ef9a438afcbe944e52"></a><!-- doxytag: member="bdm::PF::resmethod" ref="a9932c7c5865954ef9a438afcbe944e52" args="" -->
 RESAMPLING_METHOD&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#a9932c7c5865954ef9a438afcbe944e52">resmethod</a></td></tr>
 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">which resampling method will be used <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">double&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1PF.html#ab16816e20f97f9bec993d1f25fc3d711">res_threshold</a></td></tr>
 <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ac400357e37d27a4834b2b1d9211009ed"></a><!-- doxytag: member="bdm::PF::drv" ref="ac400357e37d27a4834b2b1d9211009ed" args="" -->
 <a class="el" href="classbdm_1_1RV.html">RV</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classbdm_1_1BM.html#ac400357e37d27a4834b2b1d9211009ed">drv</a></td></tr>
@@ -230,5 +260,5 @@
 <div class="fragment"><pre class="fragment"> BM* <a class="code" href="classbdm_1_1BM.html#a40f01563651c1e4fe926189e41a6b8ab">_copy_</a>()<span class="keyword"> const </span>{<span class="keywordflow">return</span> <span class="keyword">new</span> BM(*<span class="keyword">this</span>);} 
 </pre></div> 
-<p>Reimplemented in <a class="el" href="classbdm_1_1ARX.html#aca0b54c0997cfd567f49377af5def106">bdm::ARX</a>, <a class="el" href="classbdm_1_1KalmanCh.html#a24ce65bdaa538d4d5153d709a929b996">bdm::KalmanCh</a>, <a class="el" href="classbdm_1_1EKFCh.html#a1d1d91400e3f177de9fe7962ea17adc4">bdm::EKFCh</a>, and <a class="el" href="classbdm_1_1BMEF.html#a62d2e4691bed41a1efa6b9c2e35e5c67">bdm::BMEF</a>.</p>
+<p>Reimplemented in <a class="el" href="classbdm_1_1ARX.html#aca0b54c0997cfd567f49377af5def106">bdm::ARX</a>, <a class="el" href="classbdm_1_1ARXfrg.html#a420f3f195d231723f2f2329ec900de60">bdm::ARXfrg</a>, <a class="el" href="classbdm_1_1KalmanCh.html#a24ce65bdaa538d4d5153d709a929b996">bdm::KalmanCh</a>, <a class="el" href="classbdm_1_1EKFCh.html#a1d1d91400e3f177de9fe7962ea17adc4">bdm::EKFCh</a>, and <a class="el" href="classbdm_1_1BMEF.html#a62d2e4691bed41a1efa6b9c2e35e5c67">bdm::BMEF</a>.</p>
 
 </div>
@@ -260,7 +290,36 @@
 <p>Implements <a class="el" href="classbdm_1_1BM.html#a60b1779a577367c369a932cabd3a6188">bdm::BM</a>.</p>
 
-<p>Reimplemented in <a class="el" href="classbdm_1_1MPF.html#a286d040770d08bd7ff416cea617b1b14">bdm::MPF&lt; BM_T &gt;</a>.</p>
-
-<p>References <a class="el" href="particles_8h_source.html#l00036">_samples</a>, <a class="el" href="particles_8h_source.html#l00034">_w</a>, <a class="el" href="particles_8h_source.html#l00032">est</a>, <a class="el" href="bdmbase_8h_source.html#l00498">bdm::mpdf::evallogcond()</a>, <a class="el" href="particles_8h_source.html#l00030">n</a>, <a class="el" href="particles_8h_source.html#l00040">obs</a>, <a class="el" href="particles_8h_source.html#l00038">par</a>, <a class="el" href="exp__family_8cpp_source.html#l00262">bdm::eEmp::resample()</a>, <a class="el" href="particles_8h_source.html#l00043">resmethod</a>, and <a class="el" href="bdmbase_8h_source.html#l00489">bdm::mpdf::samplecond()</a>.</p>
+<p>References <a class="el" href="particles_8h_source.html#l00036">_samples</a>, <a class="el" href="particles_8cpp_source.html#l00007">bayes_gensmp()</a>, <a class="el" href="particles_8cpp_source.html#l00015">bayes_weights()</a>, <a class="el" href="particles_8h_source.html#l00099">do_resampling()</a>, <a class="el" href="particles_8h_source.html#l00032">est</a>, <a class="el" href="particles_8h_source.html#l00042">lls</a>, <a class="el" href="particles_8h_source.html#l00030">n</a>, <a class="el" href="particles_8h_source.html#l00040">obs</a>, <a class="el" href="exp__family_8cpp_source.html#l00265">bdm::eEmp::resample()</a>, and <a class="el" href="particles_8h_source.html#l00045">resmethod</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a40d74160df73d152a9bcf044eac25663"></a><!-- doxytag: member="bdm::PF::from_setting" ref="a40d74160df73d152a9bcf044eac25663" args="(const Setting &amp;set)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void bdm::PF::from_setting </td>
+          <td>(</td>
+          <td class="paramtype">const Setting &amp;&nbsp;</td>
+          <td class="paramname"> <em>set</em></td>
+          <td>&nbsp;)&nbsp;</td>
+          <td><code> [inline, virtual]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>configuration structure for basic <a class="el" href="classbdm_1_1PF.html" title="Trivial particle filter with proposal density equal to parameter evolution model...">PF</a> </p>
+<div class="fragment"><pre class="fragment">        parameter_pdf   = mpdf_class;         <span class="comment">// parameter evolution pdf</span>
+        observation_pdf = mpdf_class;         <span class="comment">// observation pdf</span>
+        prior           = epdf_class;         <span class="comment">// prior probability density</span>
+        --- optional ---
+        n               = 10;                 <span class="comment">// number of particles</span>
+        <a class="code" href="classbdm_1_1PF.html#a9932c7c5865954ef9a438afcbe944e52" title="which resampling method will be used">resmethod</a>       = <span class="stringliteral">&apos;systematic&apos;</span>, or <span class="stringliteral">&apos;multinomial&apos;</span>, or <span class="stringliteral">&apos;stratified&apos;</span>
+                                                                                  <span class="comment">// resampling method</span>
+        <a class="code" href="classbdm_1_1PF.html#ab16816e20f97f9bec993d1f25fc3d711">res_threshold</a>   = 0.5;                <span class="comment">// resample when active particles drop below 50%</span>
+</pre></div> 
+<p>Reimplemented from <a class="el" href="classbdm_1_1BM.html#a23c6a8f71f922023ab08dcb0487a86de">bdm::BM</a>.</p>
+
+<p>References <a class="el" href="bdmbase_8cpp_source.html#l00101">bdm::RV::add()</a>, <a class="el" href="particles_8h_source.html#l00040">obs</a>, <a class="el" href="particles_8h_source.html#l00038">par</a>, <a class="el" href="particles_8h_source.html#l00166">prior_from_set()</a>, and <a class="el" href="particles_8h_source.html#l00142">resmethod_from_set()</a>.</p>
 
 </div>
@@ -306,11 +365,30 @@
 </div>
 <div class="memdoc">
-<p>Set posterior density by sampling from epdf0 </p>
+<p>Set posterior density by sampling from epdf0 Extends original <a class="el" href="classbdm_1_1BM.html#aadb539fa2585c8a2a91c54e5aebf330e" title="Set boolean options from a string, recognized are: &quot;logbounds,logll&quot;.">BM::set_options</a> by two more options: </p>
+<ul>
+<li>logweights - meaning that all weightes will be logged </li>
+<li>logsamples - all samples will be also logged </li>
+</ul>
 
 <p>Reimplemented from <a class="el" href="classbdm_1_1BM.html#aadb539fa2585c8a2a91c54e5aebf330e">bdm::BM</a>.</p>
 
-<p>Reimplemented in <a class="el" href="classbdm_1_1MPF.html#a2e95498dec734088ab9f4878ff404144">bdm::MPF&lt; BM_T &gt;</a>.</p>
-
-<p>References <a class="el" href="particles_8h_source.html#l00049">opt_L_smp</a>, and <a class="el" href="particles_8h_source.html#l00051">opt_L_wei</a>.</p>
+<p>References <a class="el" href="particles_8h_source.html#l00054">opt_L_smp</a>, and <a class="el" href="particles_8h_source.html#l00056">opt_L_wei</a>.</p>
+
+</div>
+</div>
+<hr/><h2>Member Data Documentation</h2>
+<a class="anchor" id="ab16816e20f97f9bec993d1f25fc3d711"></a><!-- doxytag: member="bdm::PF::res_threshold" ref="ab16816e20f97f9bec993d1f25fc3d711" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">double <a class="el" href="classbdm_1_1PF.html#ab16816e20f97f9bec993d1f25fc3d711">bdm::PF::res_threshold</a><code> [protected]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>resampling threshold; in this case its meaning is minimum ratio of active particles For example, for 0.5 resampling is performed when the numebr of active aprticles drops belo 50%. </p>
+
+<p>Referenced by <a class="el" href="particles_8h_source.html#l00099">do_resampling()</a>, and <a class="el" href="particles_8h_source.html#l00142">resmethod_from_set()</a>.</p>
 
 </div>
@@ -321,5 +399,5 @@
 </ul>
 </div>
-<hr size="1"/><address style="text-align: right;"><small>Generated on Fri Sep 18 00:12:04 2009 for mixpp by&nbsp;
+<hr size="1"/><address style="text-align: right;"><small>Generated on Sun Sep 27 00:49:06 2009 for mixpp by&nbsp;
 <a href="http://www.doxygen.org/index.html">
 <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.1 </small></address>
