Changeset 741
- Timestamp:
- 11/26/09 22:46:01 (15 years ago)
- Location:
- library
- Files:
-
- 7 modified
Legend:
- Unmodified
- Added
- Removed
-
library/bdm/base/bdmbase.h
r738 r741 437 437 //! Array<vec> version of evallogcond 438 438 virtual vec evallogcond_mat ( const Array<vec> &Yt, const vec &cond ) { 439 bdm_error ( "Not implemented" ); 440 return vec(); 439 vec v ( Yt.length() ); 440 for ( int i = 0; i < Yt.length(); i++ ) { 441 v ( i ) = evallogcond ( Yt( i ), cond ); 442 } 443 return v; 441 444 } 442 445 -
library/bdm/estim/arx.cpp
r738 r741 12 12 13 13 dyad.set_subvector ( 0, yt ); 14 dyad.set_subvector ( dimy, cond ); 14 if (cond.length()>0) 15 dyad.set_subvector ( dimy, cond ); 15 16 // possible "1" is there from the beginning 16 17 -
library/bdm/estim/mixtures.h
r737 r741 77 77 Coms ( i ) = ( BMEF* ) Coms0 ( i )->_copy_(); 78 78 } 79 weights.set_parameters(alpha0); 80 weights.validate(); 79 81 build_est(); 80 82 } -
library/bdm/stat/exp_family.h
r739 r741 518 518 void set_parameters ( const vec &beta0 ) { 519 519 est.set_parameters ( beta0 ); 520 est.validate(); 520 521 if ( evalll ) { 521 522 last_lognc = est.lognc(); -
library/bdm/stat/merger.cpp
r739 r741 204 204 ARX A0; 205 205 A0.set_statistics ( dim, V0 ); //initial guess of Mix: 206 A0.validate(); 206 207 207 208 Mix.init ( &A0, Smp_ex, Ncoms ); -
library/tests/stresssuite/merger_iter_stress.cpp
r721 r741 27 27 28 28 f1->set_parameters ( "4 3", mat ( "0.4 0.3; 0.3 0.4" ) ); 29 f1->validate(); 29 30 f2->set_parameters ( "1 3", mat ( "0.3 -0.2; -0.2 0.3" ) ); 31 f2->validate(); 30 32 f3->set_parameters ( "2", mat ( "0.4" ) ); 31 33 f3->validate(); 34 32 35 pdf_array A ( 3 ); 33 36 A ( 0 ) = f1; … … 49 52 g0.set_rv ( xy ); 50 53 g0.set_parameters ( vec ( "4 4" ), mat ( "1 0; 0 1" ) ); 51 54 g0.validate(); 55 52 56 M.set_parameters ( 5 ); 53 57 M.set_method ( LOGNORMAL, 1.2 ); 54 58 M.set_support ( g0, 400 ); 59 M.validate(); 55 60 M.merge(); 61 56 62 57 63 MixEF &MM = M._Mix(); -
library/tests/stresssuite/mixtures_stress.cpp
r722 r741 88 88 ARX M1; 89 89 M1.set_statistics ( 2, V0 - Vp, 8 ); 90 M1.validate(); 90 91 ARX M2; 91 92 M2.set_statistics ( 2, V0 + Vp, 8 ); 93 M2.validate(); 92 94 93 95 // Build mixture model … … 110 112 ARX Aflat; 111 113 Aflat.set_statistics ( 2, V0, 7 ); 114 Aflat.validate(); 112 115 MixEF RND; 113 116 RND.init ( &Aflat, Data, 10 ); // already initialized!