Changeset 1187
- Timestamp:
- 09/16/10 13:21:51 (14 years ago)
- Location:
- library/bdm/estim
- Files:
-
- 2 modified
Legend:
- Unmodified
- Added
- Removed
-
library/bdm/estim/particles.cpp
r1064 r1187 43 43 bayes_weights(); 44 44 45 if (log_level[logweights]) { 46 log_level.store( logweights, w); 47 } 48 45 49 if ( do_resampling() ) { 46 50 resample ( ); -
library/bdm/estim/particles.h
r1177 r1187 408 408 void log_write ( ) const { 409 409 BM::log_write(); 410 if (log_level[logweights]) { 411 log_level.store( logweights, w); 412 } 410 // weigths are before resamplign -- bayes 413 411 if (log_level[logmeans]) { 414 412 for (int i=0; i<particles.length(); i++) { … … 731 729 732 730 vec z_y =h->eval(h_args)-dt; 733 ARX *abm = dynamic_cast<ARX*>(bmy.get());734 double ll2;731 // ARX *abm = dynamic_cast<ARX*>(bmy.get()); 732 /* double ll2; 735 733 if (abm){ //ARX 736 734 shared_ptr<epdf> pr_y(abm->epredictor_student(empty_vec)); … … 739 737 shared_ptr<epdf> pr_y(bmy->epredictor(empty_vec)); 740 738 ll2=pr_y->evallog(z_y); 741 } 739 }*/ 742 740 743 741 bmy->bayes(z_y); 744 742 // test _lls 745 ll= ll2;//bmy->_ll();743 ll= bmy->_ll(); 746 744 } 747 745 void from_setting(const Setting &set) {